Re: PHP 4.0 Bug #10668 Updated: preg_replace backquote failure
| From: | Andrei Zmievski | Date: | Fri, 04 May 2001 19:37:42 +0000 |
| Subject: | Re: PHP 4.0 Bug #10668 Updated: preg_replace backquote failure | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-53943@lists.php.net to get a copy of this message | ||
On Fri, 04 May 2001, smoonen@andstuff.org wrote:
> ID: 10668
> User Update by: smoonen@andstuff.org
> Status: Analyzed
> Bug Type: PCRE related
> Description: preg_replace backquote failure
>
> H'm... I'm confused. :-) To complicate things further, the e-mails display half as
> many backslashes as the web page. :-) Since I'm not sure what you mean, I'll exhaustively
> list the behaviors:
>
> The following:
>
> $str = "abc'\\\\''def";
> function f($s) { var_dump($s); return "x"; }
> print preg_replace("/c(.*)d/e", "f('\\1')", $str);
>
> gives the error messages I posted earlier. (That's two backslashes before the 1.)
Ok, this example does not give me any errors. Can you try the latest CVS
and see if that works for you?
-Andrei
* What were the first 15 billion years of the universe like for you? *