Simple question----- if (!$result) {
Posted: Mon Feb 28, 2005 8:53 pm
I found this method in the php.net manual and it wont go into the if statement if there is an Invalid Query. Regardless of what is entered, it skips it.
http://us4.php.net/manual/en/function.mysql-query.php
Code: Select all
$result = mysql_query("SELECT * FROM links WHERE nick = '$name_entered' ");
if (!$result) {
die ("Error, No match in db. " . mysql_error());
} // end ifhttp://us4.php.net/manual/en/function.mysql-query.php