Re: filter_var options effect \0 even if it FILTER_FLAG_STRIP_LOW not used?
| From: | Pierre | Date: | Sun, 11 Feb 2007 10:38:56 +0000 |
| Subject: | Re: filter_var options effect \0 even if it FILTER_FLAG_STRIP_LOW not used? | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-28002@lists.php.net to get a copy of this message | ||
Hi,
On 2/11/07, Andy Mason <slackmase2@gmail.com> wrote:
Is the filter_var function automagically removing the \0 ?Not magically, it is normal and expected. You can keep these kind of values using one of the encode flags, like: $a= filter_var("abc\0\r\n", FILTER_SANITIZE_STRING, FILTER_FLAG_ENCODE_LOW)); --Pierre