Redirect to /login when there is no session (enforcing) + New templates
This commit is contained in:
parent
cc186de4aa
commit
c396898925
|
@ -0,0 +1,2 @@
|
||||||
|
</body>
|
||||||
|
</html>
|
|
@ -0,0 +1,15 @@
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title><?php echo $title ?? '' ?></title>
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<!-- TODO: include later
|
||||||
|
<link rel="manifest" href="/manifest.json">
|
||||||
|
<link rel="stylesheet" href="/fonts/forkawesome/css/fork-awesome.min.css">
|
||||||
|
<script type="application/javascript" src="/js/dayjs.min.js"></script>
|
||||||
|
<script type="application/javascript" src="/js/relativeTime.js"></script>
|
||||||
|
<script type="application/javascript" src="/js/updateLocale.js"></script>
|
||||||
|
-->
|
||||||
|
<?php tpl_styles($styles ?? null) ?>
|
||||||
|
<?php tpl_scripts($scripts ?? null) ?>
|
||||||
|
</head>
|
||||||
|
<body>
|
|
@ -1,6 +1,6 @@
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title><?php echo $title ?></title>
|
<title><?php echo $title ?? '' ?></title>
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<!-- TODO: include later
|
<!-- TODO: include later
|
||||||
<link rel="manifest" href="/manifest.json">
|
<link rel="manifest" href="/manifest.json">
|
||||||
|
|
|
@ -1,5 +1,12 @@
|
||||||
<?php require 'base.php' ?>
|
<?php require 'base.php' ?>
|
||||||
<?php session_enforce() ?>
|
<?php session_enforce(APP_DIR.'/login') ?>
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
echo $_SERVER['REQUEST_URI'];
|
$args = urlargs(1);
|
||||||
|
$uri = '/'.implode('/', $args);
|
||||||
|
?>
|
||||||
|
<?php tpl('app.header') ?>
|
||||||
|
<main>
|
||||||
|
APP HERE
|
||||||
|
</main>
|
||||||
|
<?php tpl('app.footer') ?>
|
||||||
|
|
Loading…
Reference in New Issue