diff options
| author | Connor Thomson <blumatrikz@gmail.com> | 2026-09-20 21:01:48 -0700 |
|---|---|---|
| committer | Connor Thomson <blumatrikz@gmail.com> | 2026-09-20 21:01:48 -0700 |
| commit | 1b35cf3f1124b161ebde5e9e3a2c74c8ea2821d0 (patch) | |
| tree | 5f1255ab93943e50685d712a6d49b7ca8e2b484b /signin/signin.php | |
| parent | 81cabf40f9063f72f04df9b720d7f0e25a185741 (diff) | |
Add status and more
Diffstat (limited to 'signin/signin.php')
| -rwxr-xr-x | signin/signin.php | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/signin/signin.php b/signin/signin.php index 6e88336..f7f3c23 100755 --- a/signin/signin.php +++ b/signin/signin.php @@ -28,7 +28,7 @@ if ($_SERVER["REQUEST_METHOD"] == "POST") { $remember = isset($_POST['remember']); try { - $sql = "SELECT id, username, password, verification_code FROM users WHERE username = :username"; + $sql = "SELECT id, username, password, status FROM users WHERE username = :username"; $user = fetch_row($sql, ['username' => $username]); } catch (\PDOException $e) { @@ -36,13 +36,12 @@ if ($_SERVER["REQUEST_METHOD"] == "POST") { exit; } - // The same message either way, so it does not say which usernames exist if (!$user || !password_verify($password, $user['password'])) { echo "Username or password is not correct!"; exit; } - if ($user['verification_code'] != '0001') { + if ($user['status'] == 'none') { set_user_id((int)$user['id']); header("Location: /signup/verify"); |
