note 45793 added to function.sqlite-escape-string
| From: | (ignore) | Date: | Sat, 18 Sep 2004 23:41:58 +0000 |
| Subject: | note 45793 added to function.sqlite-escape-string | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-76955@lists.php.net to get a copy of this message | ||
On my PHP version (5.0.0), sqlite_escape_string returns crap when the argument is an empty string.
As you can imagine this may cause problems ;), so I use a wrapper function:
// Weird bug in sqlite_escape_string, apparently
function fixed_sqlite_escape_string($string) {
if($string === '') {
return '';
}
else {
return sqlite_escape_string($string);
}
}
----
Manual Page -- http://www.php.net/manual/en/function.sqlite-escape-string.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+45793
Delete -- http://master.php.net/manage/user-notes.php?action=delete+45793&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+45793&report=yes
Search -- http://master.php.net/manage/user-notes.php