It's a bug. Try the latest CVS, it has been fixed.
Shaun Thomas wrote:
>
> This only applies to PHP 4.0.4
>
> Back with PHP 4.0.2, I could do this:
>
> $string = "[[";
> $string = preg_replace("/(\W)/", "1", $string);
> ?>
>
> $string would then contain "\[\[".
>
> Now, if I use that sa
> This only applies to PHP 4.0.4
>
> Back with PHP 4.0.2, I could do this:
>
> $string = "[[";
> $string = preg_replace("/(\W)/", "1", $string);
> ?>
>
> $string would then contain "\[\[".
>
> Now, if I use that same code, $string contains "\\1\\1\\1\\1".
>
> I tried to compensate for th
> $string = "[[";
Okay. I don't think [ is special in PHP. { is a new special character,
though.
> $string = preg_replace("/(\W)/", "1", $string);
\W -- what's that? You probably need \\W there...
> ?>
>
> $string would then contain "\[\[".
I dunno about that. This Regex stuff is ov
This only applies to PHP 4.0.4
Back with PHP 4.0.2, I could do this:
$string would then contain "\[\[".
Now, if I use that same code, $string contains "\\1\\1\\1\\1".
I tried to compensate for this using PHP's new ability to allow
perl syntax in the replace section.
That leaves $string w
4 matches
Mail list logo