Added routes

This commit is contained in:
neerholt
2021-03-17 09:43:09 +01:00
parent 0d4f161a48
commit a84c7a9258
14 changed files with 148 additions and 54 deletions
+8 -3
View File
@@ -14,11 +14,17 @@ if(isset($_POST['1Vote'])){
$vote->points += 1;
if(!empty($_POST['comment'])){
$vote->comment = $_POST['comment'];
}else{
header("location: ../../../Frontend/index.html?error=EmptyField");
exit();
}
$vote->save();
header("location: ../../../Frontend/index.html?success=YouHaveVoted");
exit();
}
}else{
header("location: ../../../Frontend/index.html?error=YouCantVoted");
exit();
}
@@ -27,4 +33,3 @@ if(isset($_POST['1Vote'])){