note 110204 added to ref.mbstring
| From: | DavidDrakard | Date: | Sun, 30 Sep 2012 19:02:44 +0000 |
| Subject: | note 110204 added to ref.mbstring | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-191079@lists.php.net to get a copy of this message | ||
My understanding is that str_replace may not work as required with multibyte strings. Example:
If you have a 2 byte encoding, then representing the bytes in hex, if you have the 3 character
string: 35 DF DF 6A DF DF
and you do the character replacement: DF DF ~> DF 42
with str_replace you get: 35 DF 42 6A DF 42
instead of: 35 DF DF 6A DF 42
For this reason you may wish to consider using another option.
----
Server IP: 69.147.83.199
Probable Submitter: 86.182.183.171
----
Manual Page -- http://www.php.net/manual/en/ref.mbstring.php
Edit -- https://master.php.net/note/edit/110204
Del: integrated -- https://master.php.net/note/delete/110204/integrated
Del: useless -- https://master.php.net/note/delete/110204/useless
Del: bad code -- https://master.php.net/note/delete/110204/bad+code
Del: spam -- https://master.php.net/note/delete/110204/spam
Del: non-english -- https://master.php.net/note/delete/110204/non-english
Del: in docs -- https://master.php.net/note/delete/110204/in+docs
Del: other reasons-- https://master.php.net/note/delete/110204
Reject -- https://master.php.net/note/reject/110204
Search -- https://master.php.net/manage/user-notes.php