From 5905888e956bcb5d8b127288bade44dd0e6aa6ac Mon Sep 17 00:00:00 2001 From: =?utf8?q?Niklas=20Laxstr=C3=B6m?= Date: Mon, 8 May 2006 16:58:07 +0000 Subject: [PATCH] * Added formatNum call * Support for {{plural:}} (ref 5805) --- RELEASE-NOTES | 2 +- includes/SpecialMostcategories.php | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 21db1b723a..cef3225c0f 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -212,7 +212,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN Special:Wantedcategories and Special:Mostlinkedcategories. * (bug 3309) Allow comments when undeleting pages * Clean up Special:Undelete a bit -* (bug 5805) message nbytes can now use {{plural:}} +* (bug 5805) messages nbytes, ncategories can now use {{plural:}} * Clean up Special:Imagelist a bit * (bug 5838) Namespace names for Nds-NL * (bug 5749) Added Tyvan language files diff --git a/includes/SpecialMostcategories.php b/includes/SpecialMostcategories.php index 2a188d9ed2..aa53323ca3 100644 --- a/includes/SpecialMostcategories.php +++ b/includes/SpecialMostcategories.php @@ -40,15 +40,18 @@ class MostcategoriesPage extends QueryPage { } function formatResult( $skin, $result ) { - global $wgContLang; + global $wgContLang, $wgLang; $nt = Title::makeTitle( $result->namespace, $result->title ); $text = $wgContLang->convert( $nt->getPrefixedText() ); $plink = $skin->makeKnownLink( $nt->getPrefixedText(), $text ); - $nl = wfMsg( 'ncategories', $result->value ); - $nlink = $skin->makeKnownLink( $wgContLang->specialPage( 'Categories' ), $nl, 'article=' . $nt->getPrefixedURL() ); + $nl = wfMsgExt( 'ncategories', array( 'parsemag', 'escape' ), + $wgLang->formatNum( $result->value ) ); + + $nlink = $skin->makeKnownLink( $wgContLang->specialPage( 'Categories' ), + $nl, 'article=' . $nt->getPrefixedURL() ); return wfSpecialList($plink, $nlink); } -- 2.20.1