Dragon-Knight/server/templates/layout.php

48 lines
1012 B
PHP

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title><?= $title ?> | <?= App::$s['game_name'] ?></title>
<link rel="stylesheet" href="/css/dragon.css">
</head>
<body>
<div id="container">
<header>
<?= render('partials/header', $data) ?>
</header>
<div id="content">
<aside id="left">
<?php if (App::$auth->good()) {
echo render('partials/left', $data);
} ?>
</aside>
<main>
<div>
<?php
if (!empty(App::$flashes)) {
foreach (App::$flashes as $type => $flash) {
echo '<div class="alert ' . $type . '">' . $flash . '</div>';
}
}
?>
</div>
<div><?= render($content, $data) ?></div>
</main>
<aside id="right">
<?php if (App::$auth->good()) {
echo render('partials/right', $data);
} ?>
</aside>
</div>
<footer>
<?= render('partials/footer', $data) ?>
</footer>
</div>
</body>
</html>