RE: [PHP] regex and newline

From: Date: Fri, 02 May 2003 03:45:56 +0000
Subject: RE: [PHP] regex and newline
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-146052@lists.php.net to get a copy of this message
> $text = "[list]\n"; > $text = preg_replace("/\[list\]\n?/i","<ul>", $text); > > What I want $text to look like is this afterwards: > $text="<ul>" Umm... str_replace("[list]\n",'<ul>',$text); ?? ---John W. Holmes... PHP Architect - A monthly magazine for PHP Professionals. Get your copy today. http://www.phparch.com/

« previous php.general (#146052) next »