From: Magnus Manske Date: Tue, 5 Aug 2003 11:51:05 +0000 (+0000) Subject: Category fix X-Git-Tag: 1.1.0~359 X-Git-Url: https://git.cyclocoop.org/%7B%24admin_url%7Dmembres/%27%20%20%20mw.html.escape%28%20mw.util.getUrl%28%20%27link%27%20%29%20%29%20%20%20%27?a=commitdiff_plain;h=daca4342f03ecd982fe253d8fcbdb084412a595a;p=lhc%2Fweb%2Fwiklou.git Category fix --- diff --git a/includes/OutputPage.php b/includes/OutputPage.php index 7f1948affd..34ea53b724 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -918,7 +918,7 @@ return $r ; /* private */ function replaceInternalLinks( $s ) { global $wgTitle, $wgUser, $wgLang; - global $wgLinkCache, $wgInterwikiMagic; + global $wgLinkCache, $wgInterwikiMagic, $wgUseCategoryMagic; global $wgNamespacesWithSubpages, $wgLanguageCode; wfProfileIn( $fname = "OutputPage::replaceInternalLinks" ); @@ -993,6 +993,10 @@ return $r ; $s .= $sk->makeMediaLink( $name, wfImageUrl( $name ), $text ); $s .= $trail; + } else if ( isset($wgUseCategoryMagic) && $wgUseCategoryMagic && $pre == wfMsg ( "category" ) ) { + $l = $sk->makeLink ( $pre.":".ucfirst($m[2]) , ucfirst ( $m[2] ) ) ; + array_push ( $this->mCategoryLinks , $l ) ; + $s .= $trail ; } else { $l = $wgLang->getLanguageName( $pre ); if ( "" == $l or !$wgInterwikiMagic or