I am building on a previous thread which got the user name by now asking for password as well.
But for some reason it doesn't work, it jumps right to the default.
Thanks for looking
Here is the code
<?php
$usern1 = Joe;
$pass1 = abc;
$usern2 = Jim;
$pass2 = lmn;
$usern3 = Jack;
$pass3 = xyz;
if ($_POST[$user] == $usern1 && $_POST[$password] == $pass1)
echo("Joe you are now logged in");
elseif ($_POST[$user] == $usern2 && $_POST[$password] == $pass2)
echo("Jim you are now logged in");
elseif ($_POST[$user] == $usern3 && $_POST[$password] == $pass3)
echo("Jack you are now logged in");
else {
echo("Login Failed");
}
?>