Closed (fixed)
Project:
Bibliography Module
Version:
6.x-1.4
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
6 May 2009 at 12:41 UTC
Updated:
16 Aug 2009 at 10:15 UTC
Hello,
I just upgraded to biblio 1.4. and encountered the following problem:
warning: preg_replace() [function.preg-replace]: Compilation failed: POSIX named classes are supported only within a class at offset 1 in /mysite.net/modules/biblio/biblio_theme.inc on line 448.
After some Google search I came across this page
http://www.dokeos.com/forum/viewtopic.php?p=5020&
which suggests that \s is more compliant than :space:
and replacing
$space = "[:space:]";
with
$space = "[\s]";
in biblio_theme.inc, line 343 indeed solves the problem.
Is that just me? General fix?
Thanks
Chris
Comments
Comment #1
rjerome commentedWhat version of PHP are you using?
What Operating System + version?
Comment #2
cfrb commentedDrupal 6.11
Biblio 1.4
Linux kernel 2.6.18-128.1.6.el5
PHP 5.1.6
Apache server
Comment #3
rjerome commentedHmm, that's pretty much identical to the software stack that I'm running on... Of special note is the pcre version, could you check that on your machine.
2.6.18-128.1.6.el5PAE
php-cli-5.1.6-23.2.el5_3
php-mysql-5.1.6-23.2.el5_3
php-pdo-5.1.6-23.2.el5_3
php-devel-5.1.6-23.2.el5_3
php-gd-5.1.6-23.2.el5_3
php-mbstring-5.1.6-23.2.el5_3
php-5.1.6-23.2.el5_3
php-xml-5.1.6-23.2.el5_3
php-pear-1.4.11-1.el4s1.1
php-common-5.1.6-23.2.el5_3httpd-2.2.3-22.el5.centos
pcre-devel-6.6-2.el5_1.7
pcre-6.6-2.el5_1.7
Comment #4
cfrb commentedI have
pcre 6.6 06 here... maybe thats the problem. I am no superuser on my server, so I might not be able to upgrade.
Chris
Comment #5
egfrith commentedI've also encountered this problem. The fix mentioned at the top of the issue seems to work. The versions of php and pcre I'm useing are almost identical (apart from the distro packaging version number) to comment #4.
Comment #6
rjerome commentedI'm not entirely sure why it was only the [:space:] named class that was causing problems, I would have expected it to be all or nothing...
Anyway, I've replaced the [:space:] class with [\s].
Ron.
Comment #7
cfrb commentedThanks Ron, and also many thanks for this great module!