1 |
<?php |
2 |
if (isset($_POST['password'])) { |
3 |
setcookie('auth',md5($_POST['password'])); |
4 |
header('Location: index.php'); |
5 |
} |
6 |
|
7 |
require_once dirname(__FILE__) . '/../app/app.php'; |
8 |
$page_content = <<<FRAGMENT |
9 |
<form action="" method="post" class="login"> |
10 |
<fieldset> |
11 |
<p class="field"> |
12 |
<label for="password">{$l10n->getString('Password:')}</label> |
13 |
<input type="password" name="password" id="password"/> |
14 |
<input type="submit" class="submit" value="{$l10n->getString('OK')}"/> |
15 |
</p> |
16 |
</fieldset> |
17 |
</form> |
18 |
FRAGMENT; |
19 |
|
20 |
$footer_extra = <<<FRAGMENT |
21 |
<script type="text/javascript"> |
22 |
<!-- |
23 |
window.onload = function() { |
24 |
document.getElementById('password').focus(); |
25 |
} |
26 |
--> |
27 |
</script> |
28 |
|
29 |
FRAGMENT; |
30 |
|
31 |
$page_id = 'admin-login'; |
32 |
$admin_access = 0; |
33 |
|
34 |
require_once dirname(__FILE__) . '/template.php'; |