diff options
author | cflip <36554078+cflip@users.noreply.github.com> | 2021-06-05 11:57:12 -0600 |
---|---|---|
committer | cflip <36554078+cflip@users.noreply.github.com> | 2021-06-05 19:26:18 -0600 |
commit | 2ae22c4a438dc3c1822b8d909a4b38a211427bee (patch) | |
tree | bc9c1eb4ffbb81f4868d17a0098f1cff012723c7 /signin.php | |
parent | 24efe49bc2b545e3a3e46d7d6f2bd1166163e52b (diff) |
Use different syntax for conditions in HTML
Diffstat (limited to 'signin.php')
-rw-r--r-- | signin.php | 30 |
1 files changed, 15 insertions, 15 deletions
@@ -1,20 +1,20 @@ <?php session_start() ?> <!DOCTYPE html> <html lang="en"> -<head> - <title>Sign in - cflip.net forum</title> - <link rel="stylesheet" href="styles/style.css"> -</head> -<body> + <head> + <title>Sign in - cflip.net forum</title> + <link rel="stylesheet" href="styles/style.css"> + </head> + <body> <?php include_once './includes/templates/header.php' ?> -<h2>Sign in</h2> -<form action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]); ?>" method="post"> - <label for="user_name">Username: </label><br> - <input type="text" name="user_name"><br> - <label for="user_pass">Password: </label><br> - <input type="password" name="user_pass"><br> - <input type="submit" name="submit"> -</form> + <h2>Sign in</h2> + <form action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]); ?>" method="post"> + <label for="user_name">Username: </label><br> + <input type="text" name="user_name"><br> + <label for="user_pass">Password: </label><br> + <input type="password" name="user_pass"><br> + <input type="submit" name="submit"> + </form> <?php include_once 'includes/error.php'; @@ -58,12 +58,12 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST') { if (!password_verify($user_pass, $user->password)) { echo 'Password does not match!'; } else { - Session::get()->sign_in($user); + Session::get()->sign_in($user); header("Location: index.php"); } } } } ?> -</body> + </body> </html> |