note 21240 deleted from function.mysql-query by didou

From: Date: Sat, 16 Aug 2003 09:26:46 +0000
Subject: note 21240 deleted from function.mysql-query by didou
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-54301@lists.php.net to get a copy of this message
Note Submitter: drew@[NO_SPAM]corrupt.co.nz ---- This is my function I have built into my "custom library" I use everywhere. Purpose: Evaluate SQL QUERY that is passed to function and handle error's without killing off PHP with fatal error. function mysql_query_eval($sql) { $mysql_eval_result = mysql_query($sql) or $mysql_eval_error = mysql_error(); if ($mysql_eval_error) { print "mysql_error: $mysql_eval_error\n"; return FALSE; } else { return $mysql_eval_result; } }

« previous php.notes (#54301) next »