Files
code-cegled/index.php
Ricsi 8dfd618042 autofocus on user search
sandwich icon fixed
user search starts at the beginning of the string
2017-01-19 23:40:58 +01:00

87 lines
1.8 KiB
PHP

<!DOCTYPE html>
<?php
setlocale(LC_ALL, 'hu_HU');
//setlocale(LC_ALL,'hungarian');
//echo date('w');
?>
<head>
<style>
</style>
<script src="/jquery-3.1.1.min.js"></script>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<?php
require('common.php');
require('event_handler.php');
$page = new page();
echo '<link rel="stylesheet" type="text/css" href="/_css/default.css">';
?>
<link rel="stylesheet" type="text/css" href="/_css/nav.css">
<link rel="stylesheet" type="text/css" href="/_css/form.css">
<link rel="stylesheet" type="text/css" href="/_css/button.css">
<link rel="stylesheet" type="text/css" href="/_css/addbutton.css">
<?php
if ($page->is_page() && $page->get_page() == "view") {
echo '<link rel="stylesheet" type="text/css" href="/_css/default_view.css">';
}
?>
<title>Badminton Coach v 0.1</title>
</head>
<body>
<div id="pageContainer">
<nav>
<?= $page->get_page_nav();?>
</nav>
<main>
<div id="loading"></div>
<div id="main_content">
<?= $page->get_page_content();?>
</div>
</main>
<footer></footer>
</div>
<script>
function onReady(callback) {
var intervalID = window.setInterval(checkReady, 1000);
function checkReady() {
if (document.getElementsByTagName('body')[0] !== undefined) {
window.clearInterval(intervalID);
callback.call(this);
}
}
}
function show(id, value) {
document.getElementById(id).style.display = value ? 'block' : 'none';
}
onReady(function () {
show('main_content', true);
show('loading', false);
//user list autofocus Firefox fix
if ($("#uk_filter_name").length) {
$("#uk_filter_name").focus();
}
});
</script>
</body>
</html>