szurubooru/src/Views/layout-normal.phtml
2014-05-14 20:31:34 +02:00

68 lines
1.9 KiB
PHTML

<?php
Assets::addStylesheet('../lib/jquery-ui/jquery-ui.css');
Assets::addStylesheet('core.css');
Assets::addScript('../lib/jquery/jquery.min.js');
Assets::addScript('../lib/jquery-ui/jquery-ui.min.js');
Assets::addScript('../lib/mousetrap/mousetrap.min.js');
Assets::addScript('core.js');
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1"/>
</head>
<body>
<script type="text/javascript">
var lastSearchQuery = <?= json_encode(
isset($this->context->transport->lastSearchQuery)
? $this->context->transport->lastSearchQuery
:'') ?>;
</script>
<nav id="top-nav">
<div class="main-wrapper">
<?php \Chibi\View::render('top-navigation', $this->context) ?>
</div>
<div class="clear"></div>
</nav>
<section id="content">
<div class="main-wrapper">
<?= \Chibi\View::render($this->context->viewName, $this->context) ?>
</div>
<div class="clear"></div>
</section>
<footer>
<div class="main-wrapper">
<hr/>
<div class="left">
<span>
<a href="<?= getConfig()->misc->githubLink ?>">
szurubooru&nbsp;<?= PropertyModel::get(PropertyModel::EngineVersion) ?>
</a>
</span>
<?php if (Access::check(new Privilege(Privilege::ListLogs))): ?>
<span><a href="<?= \Chibi\Router::linkTo(['LogController', 'listView']) ?>">Logs</a></span>
<?php endif ?>
</div>
<div class="right">
<span><?= TextHelper::useBytesUnits(memory_get_usage()) ?></span>
<span><?= sprintf('%.04f', microtime(true) - $this->context->startTime) ?>s</span>
<span><?= count(\Chibi\Database::getLogs()) ?> queries</span>
</div>
<div class="clear"></div>
<hr/>
</div>
</footer>
<?php if (getConfig()->misc->debugQueries): ?>
<?= \Chibi\View::render('debug', $this->context) ?>
<?php endif ?>
<div id="small-screen"></div>
</body>
</html>