Hi all,
I'm trying to get php5-pcre working with utf-8 support. Here is the test case:
<?php
if (@preg_match('/\pL/u', 'a') == 1) {
echo "PCRE unicode support is turned on.\n";
} else {
echo "PCRE unicode support is turned off.\n";
}
?>
And the result is "PCRE unicode support is turned off". I have the following installed:
# pkg_info |grep pcre
pcre-7.8 Perl Compatible Regular Expressions library
php5-pcre-5.2.6_2 The pcre shared extension for php
And this is the output from pcretest -C:
PCRE version 7.8 2008-09-05
Compiled with
UTF-8 support
Unicode properties support
Newline sequence is LF
\R matches all Unicode newlines
Internal link size = 2
POSIX malloc threshold = 10
Default match limit = 10000000
Default recursion depth limit = 10000000
Match recursion uses stack
I'm using FreeBSD 6 stable. This is the output from uname:
FreeBSD xxxx 6.3-STABLE FreeBSD 6.3-STABLE #2: Mon Aug 4 16:50:44 EEST 2008
I tried to reinstall pcre and php5-pcre, but the result is the same. Any suggestions are welcome.
Tanks in advance !
I'm trying to get php5-pcre working with utf-8 support. Here is the test case:
<?php
if (@preg_match('/\pL/u', 'a') == 1) {
echo "PCRE unicode support is turned on.\n";
} else {
echo "PCRE unicode support is turned off.\n";
}
?>
And the result is "PCRE unicode support is turned off". I have the following installed:
# pkg_info |grep pcre
pcre-7.8 Perl Compatible Regular Expressions library
php5-pcre-5.2.6_2 The pcre shared extension for php
And this is the output from pcretest -C:
PCRE version 7.8 2008-09-05
Compiled with
UTF-8 support
Unicode properties support
Newline sequence is LF
\R matches all Unicode newlines
Internal link size = 2
POSIX malloc threshold = 10
Default match limit = 10000000
Default recursion depth limit = 10000000
Match recursion uses stack
I'm using FreeBSD 6 stable. This is the output from uname:
FreeBSD xxxx 6.3-STABLE FreeBSD 6.3-STABLE #2: Mon Aug 4 16:50:44 EEST 2008
I tried to reinstall pcre and php5-pcre, but the result is the same. Any suggestions are welcome.
Tanks in advance !