Re: note 9682 added to ereg_replace
| From: | Ron Chmara | Date: | Sun, 19 Nov 2000 03:25:27 +0000 |
| Subject: | Re: note 9682 added to ereg_replace | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-7874@lists.php.net to get a copy of this message | ||
cculver@memphis.edu wrote:
> I saw above that someone stated that you needed to use the ASCII code for a carriage return to
> replace it. Actually, this method is a lot easier:
> $News = ereg_replace ("\n", "<br>", $News);
> In this case, it replaces every carriage return in the $News string with a <BR> basically
> converting it into HTML.
I've removed this note, not only was it a duplicate, (triplicate, actually) it's a
expensive (slow) version of nl2br().
Sorry. :(
-ronabop@php.net
--
Brought to you from iBop the iMac, a MacOS, Win95, Win98, LinuxPPC machine,
which is currently in MacOS land. Your bopping may vary.