From 5bbd812189c92b4128aa4c6f97a7a2a26bafd28e Mon Sep 17 00:00:00 2001 From: Lan Hui Date: Sun, 15 Sep 2024 16:02:40 +0800 Subject: [PATCH] Fix bug 430 --- Script.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Script.php b/Script.php index 93a798f..3db0e5f 100644 --- a/Script.php +++ b/Script.php @@ -119,7 +119,7 @@ if (!empty($_POST["form_signup"])) { if (!empty($_POST["form_signup"])) { $fullname = mysqli_real_escape_string($con, $_POST["fullname"]); $student_id = mysqli_real_escape_string($con, $_POST["user_student_id"]); -<<<<<<< HEAD + $email = mysqli_real_escape_string($con, $_POST["email"]); $password = mysqli_real_escape_string($con, $_POST["password"]); $confirmpassword = mysqli_real_escape_string($con, $_POST["confirmpassword"]); @@ -168,13 +168,11 @@ if (!empty($_POST["form_signup"])) { return; } -======= - $_SESSION['user_fullname'] = $fullname; + $_SESSION['user_type'] = "Student"; $_SESSION['user_email'] = $email; $_SESSION['user_student_id'] = $student_id; ->>>>>>> fde44f76006082d6bda9431727d06cbd23a134be // apply password_hash() $password_hash = password_hash($password, PASSWORD_DEFAULT); $sql = "INSERT INTO `users_table`(`Email`, `Password`, `Full_Name`, `UserType`, `Student_ID`) VALUES "