órai
This commit is contained in:
parent
db203dbf20
commit
e3c54b3488
48
Backend/harmadik.php
Normal file
48
Backend/harmadik.php
Normal file
|
@ -0,0 +1,48 @@
|
|||
<?php
|
||||
$method = "POST";
|
||||
$islogin = false;
|
||||
/*if (isset($_GET["kod"]) && $_GET["kod"]=1111)
|
||||
{
|
||||
$islogin = true;
|
||||
}*/
|
||||
if (isset($_POST['kod']))
|
||||
switch ($_POST['kod'])
|
||||
{
|
||||
case 1111:
|
||||
case 2222:
|
||||
case 3333:
|
||||
case 4444: $islogin = true;
|
||||
break;
|
||||
|
||||
default:
|
||||
$islogin = false;
|
||||
break;
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport"
|
||||
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||
<title>suta</title>
|
||||
</head>
|
||||
<body>
|
||||
<?php if ($islogin ==false)
|
||||
{ ?>
|
||||
<form method="<?php echo $method; ?>">
|
||||
<input type="text" name="nev"><br>
|
||||
<input type="number" name="kod" min="1000" max="9999" title="Adja meg a kódot"><br>
|
||||
<input type="submit" value="Belépés">
|
||||
</form>
|
||||
<?php
|
||||
}
|
||||
else
|
||||
echo "<h1>Üdvözöllek".$_POST["nev"]."</h1>";
|
||||
echo "<a href='index.php'>Kijelentkezés</a>"
|
||||
?>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in New Issue
Block a user