note 101676 added to function.addslashes
| From: | phil dot allen at internode dot on dot net | Date: | Tue, 04 Jan 2011 05:51:30 +0000 |
| Subject: | note 101676 added to function.addslashes | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-175437@lists.php.net to get a copy of this message | ||
An interesting 'bug' with addslashes.
echo stripslashes("\'201111\' AS DATE) CAST(");
returns
'201111' AS DATE# CAST#
(changes the brackets to #)
This is very specific to this string and works the same whether the string is passed into addslashes
as a variable or string literal.
----
Server IP: 69.147.83.197
Probable Submitter: 121.127.196.60
----
Manual Page -- http://www.php.net/manual/en/function.addslashes.php
Edit -- https://master.php.net/note/edit/101676
Del: integrated -- https://master.php.net/note/delete/101676/integrated
Del: useless -- https://master.php.net/note/delete/101676/useless
Del: bad code -- https://master.php.net/note/delete/101676/bad+code
Del: spam -- https://master.php.net/note/delete/101676/spam
Del: non-english -- https://master.php.net/note/delete/101676/non-english
Del: in docs -- https://master.php.net/note/delete/101676/in+docs
Del: other reasons-- https://master.php.net/note/delete/101676
Reject -- https://master.php.net/note/reject/101676
Search -- https://master.php.net/manage/user-notes.php