kigroy Posted December 16, 2008 Share Posted December 16, 2008 What do call the exclamation point in the following code: if (!$result) { $message = 'Invalid query: ' . mysql_error() . "\n"; $message .= 'Whole query: ' . $query; die($message); } I don't know what it's called so I can't look it up at php.net. ??? Thanks... Quote Link to comment Share on other sites More sharing options...
mmarif4u Posted December 16, 2008 Share Posted December 16, 2008 It represent NOT. Quote Link to comment Share on other sites More sharing options...
xtopolis Posted December 16, 2008 Share Posted December 16, 2008 $result is referring to the outcome of $result = mysql_query($sql); If the query works, it returns with a resource id pointer (equivalent to TRUE), and if it fails it returns FALSE. That code says: if("if NOT TRUE // if equivalent of FALSE") { //show the query debug errors } Quote Link to comment Share on other sites More sharing options...
kigroy Posted December 16, 2008 Author Share Posted December 16, 2008 thanks to both of you! very helpful. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.