chiro-canto/public/auth/login/index.php

41 lines
1.6 KiB
PHP
Executable File

<?php
session_start();
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
$root = realpath($_SERVER["DOCUMENT_ROOT"]);
require("$root/lang/gettext.php");
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title><?=_('Login')?> | Chiro - Canto</title>
<link rel="stylesheet" type="text/css" href="/styles/style.css">
</head>
<?php
include("$root/analytics/matomo.php");
include("$root/analytics/owa.php");
?>
<body>
<?php include("$root/menu.php");?>
<?php include("$root/header.php");?>
<section>
<h2><?=_('Login')?></h2>
<?=(isset($_SESSION['error_msg']) and ! $_SESSION['error_msg'] == "" ) ? '<div class="error">'.$_SESSION['error_msg'].'</div>' : ""?>
<form action="login.php" method="post">
<label for="username"><?=_('Username')?>*</label>
<input id="username" type="text" name="username" placeholder="<?=_('Enter your username..')?>" required>
<label for="password">Password*</label>
<input type="password" name="password" id="password" placeholder="<?=_('Enter your password..')?>" required>
<input type="submit" name="submit" value="<?=_('submit')?>"><input type="reset" name="reset" value="<?=_('reset')?>">
</form>
<a href="/auth/register"><?=_('Not yet registered ?')?></a>
</section>
<?php include("$root/footer.php");?>
</body>
<script src="/scripts/script.js"></script>
</html>