note 94828 added to filter.filters.sanitize
| From: | marcus at synchromedia dot co dot uk | Date: | Fri, 27 Nov 2009 09:07:04 +0000 |
| Subject: | note 94828 added to filter.filters.sanitize | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-163324@lists.php.net to get a copy of this message | ||
It's not entirely clear what the LOW and HIGH ranges are. LOW is characters below 32, HIGH is
those above 127, i.e. outside the ASCII range.
<?php
$a = "\tcafé\n";
//This will remove the tab and the line break
echo filter_var($a, FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_LOW);
//This will remove the é.
echo filter_var($a, FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_HIGH);
?>
----
Server IP: 195.221.21.36
Probable Submitter: 79.81.243.102
----
Manual Page -- http://www.php.net/manual/en/filter.filters.sanitize.php
Edit -- https://master.php.net/note/edit/94828
Del: integrated -- https://master.php.net/note/delete/94828/integrated
Del: useless -- https://master.php.net/note/delete/94828/useless
Del: bad code -- https://master.php.net/note/delete/94828/bad+code
Del: spam -- https://master.php.net/note/delete/94828/spam
Del: non-english -- https://master.php.net/note/delete/94828/non-english
Del: in docs -- https://master.php.net/note/delete/94828/in+docs
Del: other reasons-- https://master.php.net/note/delete/94828
Reject -- https://master.php.net/note/reject/94828
Search -- https://master.php.net/manage/user-notes.php