From: Gabriel Wicke Date: Fri, 24 Mar 2006 16:44:52 +0000 (+0000) Subject: Handle {{/subpage}} properly X-Git-Tag: 1.6.0~152 X-Git-Url: https://git.cyclocoop.org/%7B%24admin_url%7Dcompta/operations/modifier.php?a=commitdiff_plain;h=660d9c07688da88d72bf29a5cb63877d94446f0b;p=lhc%2Fweb%2Fwiklou.git Handle {{/subpage}} properly --- diff --git a/includes/Parser.php b/includes/Parser.php index ff66e1314f..4329bd180d 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -2616,7 +2616,11 @@ class Parser $lastPathLevel = $this->mTemplatePath; if ( !$found ) { $ns = NS_TEMPLATE; - $part1 = $this->maybeDoSubpageLink( $part1, $subpage='' ); + # declaring $subpage directly in the function call + # does not work correctly with references and breaks + # {{/subpage}}-style inclusions + $subpage = ''; + $part1 = $this->maybeDoSubpageLink( $part1, $subpage ); if ($subpage !== '') { $ns = $this->mTitle->getNamespace(); }