2
This commit is contained in:
parent
3ba44cb90a
commit
98aa2e3c0c
@ -17,8 +17,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
|||||||
$stmt->execute([$username]);
|
$stmt->execute([$username]);
|
||||||
$user = $stmt->fetch();
|
$user = $stmt->fetch();
|
||||||
|
|
||||||
<?php
|
if ($user && password_verify($password, $user['password'])) {
|
||||||
if (password_verify($password, $user['password'])) {
|
|
||||||
$_SESSION['user_id'] = $user['id'];
|
$_SESSION['user_id'] = $user['id'];
|
||||||
$_SESSION['username'] = $user['username'];
|
$_SESSION['username'] = $user['username'];
|
||||||
header('Location: index.php');
|
header('Location: index.php');
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user