note 51394 deleted from function.mysql-real-escape-string by aidan

From: Date: Sat, 04 Feb 2006 12:07:18 +0000
Subject: note 51394 deleted from function.mysql-real-escape-string by aidan
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-102989@lists.php.net to get a copy of this message
Note Submitter: phpcoder at r4f dot org ---- Thanks boris-pieper AT t-online DOT de, but I had a pb with "PHP Version 4.1.2". I was forced to explicitely "return" from my function, which now becomes : function escape_string($string,$dbcon=false) { if(version_compare(phpversion(),"4.3.0")== -1) { return(mysql_escape_string($string)); } elseif ($dbcon) { return(mysql_real_escape_string($string,$dbcon)); } else { return false; } }

« previous php.notes (#102989) next »