Merge branch 'master' of https://git.williammiceli.systems/williammiceli-educational/CS4430-Project
This commit is contained in:
@@ -3,14 +3,14 @@ server {
|
|||||||
listen [::]:80;
|
listen [::]:80;
|
||||||
|
|
||||||
root /var/www/;
|
root /var/www/;
|
||||||
index landingPage.html
|
index index.html
|
||||||
server_name _;
|
server_name _;
|
||||||
|
|
||||||
access_log /var/log/nginx/access.log;
|
access_log /var/log/nginx/access.log;
|
||||||
error_log /var/log/nginx/error.log;
|
error_log /var/log/nginx/error.log;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
try_files $uri $uri/ /landingPage.html =404;
|
try_files $uri $uri/ /index.html =404;
|
||||||
}
|
}
|
||||||
|
|
||||||
location ~ \.php$ {
|
location ~ \.php$ {
|
||||||
|
|||||||
@@ -1,21 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html>
|
|
||||||
<body>
|
|
||||||
<style>
|
|
||||||
body {
|
|
||||||
background-color: #3B5998;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
<h2><font color="white">Friendbook</h2>
|
|
||||||
|
|
||||||
<button type="button" onclick="window.location.href = 'friends.html'">See Friends</button>
|
|
||||||
<button type="button" onclick="window.location.href = 'messages.html'">See Messages</button>
|
|
||||||
<button type="button" onclick="window.location.href = 'contacts.html'">See Contacts</button>
|
|
||||||
<button type="button" onclick="window.location.href = 'search.php'">Search</button>
|
|
||||||
<button type="button" onclick="window.location.href = 'sendMessage.php'">Message Someone</button>
|
|
||||||
<button type="button" onclick="window.location.href = 'findFriend.html'">Find a New Friend</button>
|
|
||||||
<button type="button" onclick="window.location.href = 'pendingFriend.html'">Check Pending Friends</button>
|
|
||||||
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -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