Simple Question
Posted: 24. March 2005 10:33
just wondering how to tell if a query return from mysql is null for example if a user tries to login and enters a name that doesnt exist:
how do i check for no return?
Thanks[/code]
- Code: Select all
$query = "SELECT * FROM user_table WHERE user = '$name'";
$result = mysql_query($query) or die('Query failed: ' . mysql_error());
if ($result == ??????){
echo "This user does not exist");
}
how do i check for no return?
Thanks[/code]