From daca4342f03ecd982fe253d8fcbdb084412a595a Mon Sep 17 00:00:00 2001 From: Magnus Manske Date: Tue, 5 Aug 2003 11:51:05 +0000 Subject: [PATCH] Category fix --- includes/OutputPage.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) 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 -- 2.20.1