So, I am trying to create a website where you enter a pin, it redirects you to a page, enter another pin, it redirects you to another page. I have two files: th1.php (the main file)
<?php //require_once"app/init.php ;?>
<!DOCTYPE HTML>
<link rel="stylesheet" type="text/css" href="style.css" />
<form action="th.php" method="POST">
<div class="container">
<input type="text" placeholder="Enter PIN" name="pin" required>
<button type="submit" name="sub" value="Submit">Submit</button>
</div>
<div class="container" style="background-color:#f1f1f1">
</div>
</form>
and th.php (the verification file)
<?php
if(isset($POST['pin']) AND !empty($POST['pin'])){
$input = $_POST['pin'];
$pinI = "6203";
$pinII = "9471";
if($input === $pinI){
header("Location:pinI.html");
}else{
if($input === $pinII){
header("Location:pinII.html");
}else{
echo "PIN INCORRECT!";
}}
}else{
echo "PIN EMPTY!";
}
but any code I insert, even the correct one, it sais PIN EMPTY!
can you help me please?