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

Kezdőlap
Üzenet törlése
Szerző: steve lu
Dátum:  
Címzett: pcre-dev
Tárgy: [pcre-dev] issue with pcre 7.8 in PHP lib
Hi,

I am running into this issue with pcre7.8 in PHP 5.2.9 version.

When I execute this code below on MacOSX, php returns 1.

print( preg_match('/[\d]/', '1') );

but on Windows, it always return 0.

If I run instead print( preg_match('/[0-9]/', '1') ), it returns 1 on
both platforms.
So, It doesn't seem to recognize \d as digit.

Note, I managed to compile php as static library and all extensions are
compiled into that one static lib.
(perhaps this causes pcre to not working as expected? I am using the
default pcre form the php source /ext/pcre/pcrelib)

Thanks,
Steve