Bien au dessus de Léandre et JL
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

31 lines
896 B

<!DOCTYPE html>
<html lang="fr">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="master.css">
<title>Bellagio</title>
</head>
<body>
<h1 style="text-align: center; margin: 0;">CASINO BELLAGIO</h1>
<?php
$return_path = "";
$users = array("admin"=>"admin", "user"=>"yahou")
//euh ça marche pas ici à régler après
$user_scores = array("admin"=>100, "user"=>200)
if(isset($_POST["username"]) and isset($_POST["password"])){
if(in_array($_POST["username"], $users) and $_POST["password"] == $users[$_POST["username"]]){
$_GET['score'] = $user_scores[$_POST["username"]];
$return_path = "casino.php";
}
else{
$_GET['error'] = 1;
$return_path = "login.php";
}
}
else{
$return_path = "login.php";
}
include($return_path);
?>
</body>
</html>