PHP is missing Perl-Compatible Regular Expression with Unicode support

netwa

Joined: 2012-08-01
Posts: 1
Posted: Wed, 2012-08-01 17:13

Hello,

I'm getting following Error:
PHP is missing Perl-Compatible Regular Expression with Unicode support

If I check on php.ini PCRE is enabled.

PCRE (Perl Compatible Regular Expressions) Support enabled
PCRE Library Version 6.6 06-Feb-2006

If I make a testfile PCRE ist working.

So whats the problem?

Thx, Alex

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Wed, 2012-08-01 18:05
Quote:
with Unicode support

This is the bit of code in the installer:

    if (!preg_match("/^.$/u", "ñ")) {
      $errors[] = "PHP is missing <a href=\"http://php.net/pcre\">Perl-Compatible Regular Expression</a> with UTF-8 support.";
    } else if (!preg_match("/^\pL$/u", "ñ")) {
      $errors[] = "PHP is missing <a href=\"http://php.net/pcre\">Perl-Compatible Regular Expression</a> with Unicode support.";
    }

I'm not a expert in this regard so if your testfile can pass the above it should work.
Some info:
http://forum.kohanaframework.org/discussion/4468/validation-regexp-problem/p1

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
mattdm

Joined: 2005-07-22
Posts: 181
Posted: Thu, 2012-08-02 01:57
netwa wrote:
Hello,

I'm getting following Error:
PHP is missing Perl-Compatible Regular Expression with Unicode support

If I check on php.ini PCRE is enabled.

PCRE (Perl Compatible Regular Expressions) Support enabled
PCRE Library Version 6.6 06-Feb-2006

If I make a testfile PCRE ist working.

So whats the problem?

Unicode support is a compile-time option in the PCRE library. It seems like yours doesn't have that support. From the version number and from that fact, I'm guessing you're on RHEL or CentOS 5.x. You'll have to either build a new version yourself, or update to a newer Linux distro. (RHEL 6 has a PCRE that works out of the box.)