Removed die(); as it might be messing with things.
This commit is contained in:
@@ -18,19 +18,16 @@
|
|||||||
$_SESSION["loginError"] = "";
|
$_SESSION["loginError"] = "";
|
||||||
// Move onto landing page
|
// Move onto landing page
|
||||||
header("Location: /landingPage.html");
|
header("Location: /landingPage.html");
|
||||||
die();
|
|
||||||
}else{
|
}else{
|
||||||
// No matching users found, send user error
|
// No matching users found, send user error
|
||||||
$_SESSION["loginError"] = "Invalid Username or Password";
|
$_SESSION["loginError"] = "Invalid Username or Password";
|
||||||
// Return to login page
|
// Return to login page
|
||||||
header("Location: /login.php");
|
header("Location: /login.php");
|
||||||
die();
|
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
// Return to login page, as credentials were not captured
|
// Return to login page, as credentials were not captured
|
||||||
$_SESSION["loginError"] = "Login credentials not found, please try again";
|
$_SESSION["loginError"] = "Login credentials not found, please try again";
|
||||||
header("Location: /login.php");
|
header("Location: /login.php");
|
||||||
die();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch(PDOException $e){
|
catch(PDOException $e){
|
||||||
|
|||||||
Reference in New Issue
Block a user