* <onlyinclude> whitespace, only strip the last newline
authorÆvar Arnfjörð Bjarmason <avar@users.mediawiki.org>
Sat, 3 Dec 2005 09:27:50 +0000 (09:27 +0000)
committerÆvar Arnfjörð Bjarmason <avar@users.mediawiki.org>
Sat, 3 Dec 2005 09:27:50 +0000 (09:27 +0000)
includes/Parser.php

index d4c3997..7679655 100644 (file)
@@ -2508,7 +2508,7 @@ class Parser
 
                        # If there are any <onlyinclude> tags, only include them
                        if ( in_string( '<onlyinclude>', $text ) && in_string( '</onlyinclude>', $text ) ) {
-                               preg_match_all( '/<onlyinclude>\n?(.*?)\n?<\/onlyinclude>/s', $text, $m );
+                               preg_match_all( '/<onlyinclude>(.*?)\n?<\/onlyinclude>/s', $text, $m );
                                $text = '';
                                foreach ($m[1] as $piece)
                                        $text .= $piece;