On Thursday 18 January 2001 07:40, Nicholas Pappas wrote:
> I was hoping someone could help me with this regular expression...
>
> $pattern = "/\[b\](.*)\[\/b\]/Ui";
> $message = preg_replace($pattern, "<B>\\1</B>", $message);
>
> The above works for:
> [b]bold text[/b]
>
> But does not work for:
> [b]bold text
> w/ newline[/b]
add a "s" modifier to the expression and
=>
$pattern = "/\[b\](.*)\[\/b\]/Uis";
--
Christian Reiniger
LGDC Webmaster (http://sunsite.dk/lgdc/)
"use the source, luke." (obi-wan gnuobi)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]