Re: [pcre-dev] issue with pcre 7.8 in PHP lib

Top Page
Delete this message
Author: Philip Hazel
Date:  
To: steve lu
CC: pcre-dev
Subject: Re: [pcre-dev] issue with pcre 7.8 in PHP lib
On Sun, 9 Aug 2009, steve lu wrote:

> When I execute this code below on MacOSX, php returns 1.
>
> print( preg_match('/[\d]/', '1') );
>
> but on Windows, it always return 0.


I strongly suspect this has nothing to do with PCRE, but everything to
do with the way it is called from PHP. I'm afraid I can't help, as I
don't know anything about PHP. (Or about MacOSX or Windows.) Have you
tested other backslashed constructs? If this were a C program, you would
need to use \\ in order to pass a single backslash to PCRE. Is it
something like that?

Philip

--
Philip Hazel