From: ThomasV Date: Wed, 17 Jun 2009 17:02:39 +0000 (+0000) Subject: fix regexp : oddly, the margin value may be negative X-Git-Tag: 1.31.0-rc.0~41327 X-Git-Url: http://git.cyclocoop.org/?a=commitdiff_plain;h=29729e7f5757147f06e6db53abd72ee327f05809;p=lhc%2Fweb%2Fwiklou.git fix regexp : oddly, the margin value may be negative --- diff --git a/includes/DjVuImage.php b/includes/DjVuImage.php index 041ef73c8b..406878d076 100644 --- a/includes/DjVuImage.php +++ b/includes/DjVuImage.php @@ -251,7 +251,7 @@ class DjVuImage { wfProfileOut( 'djvutxt' ); if( $retval == 0) { $txt = htmlspecialchars($txt); - $txt = preg_replace( "/\((page\s\d*\s\d*\s\d*\s\d*\s*\"([^<]*?)\"\s*|)\)/s", "", $txt ); + $txt = preg_replace( "/\((page\s[\d-]*\s[\d-]*\s[\d-]*\s[\d-]*\s*\"([^<]*?)\"\s*|)\)/s", "", $txt ); $txt = "\n\n\n" . $txt . "\n\n"; $xml = preg_replace( "//", "", $xml ); $xml = $xml . $txt. '' ;