note 24606 added to function.preg-replace
| From: | gherson@php.net | Date: | Thu, 22 Aug 2002 19:37:29 +0000 |
| Subject: | note 24606 added to function.preg-replace | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-35376@lists.php.net to get a copy of this message | ||
Pls make this (or something just as simple) your first example:
echo preg_replace("/off/","on","it's off");
This echos "it's on".
This shows that arrays aren't needed but that slashes for the pattern are (to avoid
"Delimiter must not be alphanumeric or backslash").
--
http://www.php.net/manual/en/function.preg-replace.php
http://master.php.net/manage/user-notes.php?action=edit+24606
http://master.php.net/manage/user-notes.php?action=delete+24606
http://master.php.net/manage/user-notes.php?action=reject+24606