note 93908 added to function.mb-ereg-replace
| From: | d-okumura | Date: | Tue, 06 Oct 2009 10:27:18 +0000 |
| Subject: | note 93908 added to function.mb-ereg-replace | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-161395@lists.php.net to get a copy of this message | ||
The above-mentioned 'mb_str_ireplace' is very useful,
but the function has a bug.
"Search target" placed on the position 0,
it may guess that mb_strpos returned false.
Modified following:
from:
while(($poz = mb_strpos($wCzymM, $coM, $offset)) !== false)
to:
while(!is_bool($poz = mb_strpos($wCzymM, $coM, $offset)))
----
Server IP: 69.147.83.197
Probable Submitter: 210.146.227.40
----
Manual Page -- http://www.php.net/manual/en/function.mb-ereg-replace.php
Edit -- https://master.php.net/note/edit/93908
Del: integrated -- https://master.php.net/note/delete/93908/integrated
Del: useless -- https://master.php.net/note/delete/93908/useless
Del: bad code -- https://master.php.net/note/delete/93908/bad+code
Del: spam -- https://master.php.net/note/delete/93908/spam
Del: non-english -- https://master.php.net/note/delete/93908/non-english
Del: in docs -- https://master.php.net/note/delete/93908/in+docs
Del: other reasons-- https://master.php.net/note/delete/93908
Reject -- https://master.php.net/note/reject/93908
Search -- https://master.php.net/manage/user-notes.php