note 41117 added to function.str-ireplace
| From: | wolfgang at bofh dot hanau dot net | Date: | Tue, 30 Mar 2004 16:25:30 +0000 |
| Subject: | note 41117 added to function.str-ireplace | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-67391@lists.php.net to get a copy of this message | ||
The solution for your problem, Jens, is changing the keys in the arrays.
- texts to replace are: array("car","silverblue","silver")
- replace with is: array("automobile",'link to description of color
silverblue','link to description os color silver')
If you do it like this, the function will first replace "silverblue" and then
"silver", and not vice-versa, which causes that silverblue isn't found thereafter.
----
Manual Page -- http://www.php.net/manual/en/function.str-ireplace.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+41117
Delete -- http://master.php.net/manage/user-notes.php?action=delete+41117&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+41117&report=yes
Search -- http://master.php.net/manage/user-notes.php