From: Ævar Arnfjörð Bjarmason Date: Sat, 26 Mar 2005 18:55:10 +0000 (+0000) Subject: * (bug 1015) this fix enables the full wikisyntax inside captions X-Git-Tag: 1.5.0alpha1~506 X-Git-Url: https://git.cyclocoop.org//%22?a=commitdiff_plain;h=98b50e1c001ace75d7e1f867cc3a93cb481e646f;p=lhc%2Fweb%2Fwiklou.git * (bug 1015) this fix enables the full wikisyntax inside captions --- diff --git a/includes/Parser.php b/includes/Parser.php index e4bd863316..49609aadd7 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -2872,6 +2872,10 @@ class Parser * 'A tree'. */ function renderImageGallery( $text ) { + # Setup the parser + global $wgUser, $wgParser, $wgTitle; + $parserOptions = ParserOptions::newFromUser( $wgUser ); + global $wgLinkCache; $ig = new ImageGallery(); $ig->setShowBytes( false ); @@ -2897,9 +2901,8 @@ class Parser $label = ''; } - # FIXME: Use the full wiki parser and add its links - # to the page's links. - $html = $this->mOptions->mSkin->formatComment( $label ); + $html = $wgParser->parse( $label , $wgTitle, $parserOptions ); + $html = $html->mText; $ig->add( Image::newFromTitle( $nt ), $html ); $wgLinkCache->addImageLinkObj( $nt );