Can someone tell me what's wrong w/ this code? It goes to the "username and password invalid" block every time I test it (although that may just be the input I'm using..) the input comes from an html form...
$query = "SELECT f_name, l_name, password, status FROM members WHERE id_no = " . $id_no
or die ("Incorrect username. Please <a href=\"javascript.go(-1)\">go back</a>");
$result = mysql_query($query, $connect);
$result_arr = mysql_fetch_array($result);
if ($result_arr[id_no] == $id_no && $result_arr[password] == $password && $result_arr[status] <= 1)
{
echo "<h1 align=\"center\">Administrator Add Member Page</h1>";
}
else
{
if (status > 1)
echo "Your status is not great enough to modify member database.";
else
echo "Your user name and password are invalid. Please <a href=\"javascript.go(-1)\">go back</a> to retry.";
}