I am trying to see if the logged in user is verified. But there is an error:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/psmcouk/public_html/colemansystems/verify.php on line 332
Here is the PHP code:
$user1 = $_SESSION['usr'];
$result = mysql_query("SELECT * FROM phpbb_members WHERE memberName=$user1");
while($row = mysql_fetch_array($result)) //LINE 332
{
$valid = $row['valid'];
}
if($valid == "1"){
echo "$user1, you're account is currently verified.";
}
I just can not see what is wrong with this code.
Thanks!