40 lines
1.5 KiB
PHP
40 lines
1.5 KiB
PHP
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>Tux gallery !</title>
|
|
<link rel="stylesheet" href="static/css/stylesheet.css">
|
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
|
|
</head>
|
|
<body>
|
|
<div class="nav-bar">
|
|
<ol>
|
|
<a href="/index.php"><li><img alt="logo" class="logo" src="static/img/logo.jpg">Tux Gallery </li></a>
|
|
<a href="/login.php"><li>Login</li></a>
|
|
</ol>
|
|
</div>
|
|
<div class="wrapper">
|
|
<form id="loginForm" method="POST" action="login.php">
|
|
<h1>Login</h1>
|
|
<p>Note : The register feature is not implemented yet !</p>
|
|
<label for="username">Username</label>
|
|
<input type="text" id="username" name="username">
|
|
<label for="password">Password</label>
|
|
<input type="password" id="password" name="password">
|
|
<input type="button" class="btn btn-primary" value="Login">
|
|
</form>
|
|
</div>
|
|
<?php
|
|
if (! empty($_POST)) {
|
|
$name = $_POST['username'];
|
|
$password = $_POST['password'];
|
|
if (empty($name)) {
|
|
echo "Username is empty";
|
|
} else {
|
|
echo $name;
|
|
}
|
|
}
|
|
?>
|
|
</body>
|
|
</html>
|