Change named capture group syntax.

This increases compatibility with really old version of
PCRE used on CentOS.

Refs #GH-681
This commit is contained in:
mark_story 2012-06-02 10:09:58 -04:00
parent 048dc8d254
commit 157e243eee

View file

@ -182,7 +182,7 @@ class ConsoleOutput {
return preg_replace('#</?(?:' . $tags . ')>#', '', $text);
}
return preg_replace_callback(
'/<(?<tag>[a-z0-9-_]+)>(?<text>.*?)<\/(\1)>/ims', array($this, '_replaceTags'), $text
'/<(?P<tag>[a-z0-9-_]+)>(?P<text>.*?)<\/(\1)>/ims', array($this, '_replaceTags'), $text
);
}