From fd545e18dc875ada10b0f248b496783a2337c8e2 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Niklas=20Laxstr=C3=B6m?= Date: Sun, 14 May 2006 18:04:16 +0000 Subject: [PATCH] * (bug 5805) {{plural:}} support for counters in some special pages * renamed members to nmembers --- RELEASE-NOTES | 1 + includes/SpecialCategories.php | 3 ++- includes/SpecialMostlinkedcategories.php | 3 ++- includes/SpecialMostrevisions.php | 3 ++- includes/SpecialPopularpages.php | 3 ++- includes/SpecialWantedcategories.php | 3 ++- languages/Messages.php | 13 +++++++------ 7 files changed, 18 insertions(+), 11 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index b12b393ccf..51fffa8858 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -268,6 +268,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 5862) Update of Belarusian translation (be) * (bug 5651) Disable section editing links for users who can't edit * (bug 5950) Improvements to French localisation +* (bug 5805) {{plural:}} support for counters in some special pages == Compatibility == diff --git a/includes/SpecialCategories.php b/includes/SpecialCategories.php index e5ff2b3464..47df89ae20 100644 --- a/includes/SpecialCategories.php +++ b/includes/SpecialCategories.php @@ -53,7 +53,8 @@ class CategoriesPage extends QueryPage { global $wgLang; $title = Title::makeTitle( NS_CATEGORY, $result->title ); $plink = $skin->makeLinkObj( $title, $title->getText() ); - $nlinks = wfMsg( 'members', $wgLang->formatNum( $result->count ) ); + $nlinks = wfMsgExt( 'nmembers', array( 'parsemag', 'escape'), + $wgLang->formatNum( $result->count ) ); return wfSpecialList($plink, $nlinks); } } diff --git a/includes/SpecialMostlinkedcategories.php b/includes/SpecialMostlinkedcategories.php index 53acbe71c3..6951e457ea 100644 --- a/includes/SpecialMostlinkedcategories.php +++ b/includes/SpecialMostlinkedcategories.php @@ -64,7 +64,8 @@ class MostlinkedCategoriesPage extends QueryPage { $plink = $skin->makeLinkObj( $nt, htmlspecialchars( $text ) ); - $nlinks = wfMsg( 'members', $wgLang->formatNum( $result->value ) ); + $nlinks = wfMsgExt( 'nmembers', array( 'parsemag', 'escape'), + $wgLang->formatNum( $result->value ) ); return wfSpecialList($plink, $nlinks); } } diff --git a/includes/SpecialMostrevisions.php b/includes/SpecialMostrevisions.php index 9bef93c411..09561ffae3 100644 --- a/includes/SpecialMostrevisions.php +++ b/includes/SpecialMostrevisions.php @@ -49,7 +49,8 @@ class MostrevisionsPage extends QueryPage { $plink = $skin->makeKnownLinkObj( $nt, $text ); - $nl = wfMsg( 'nrevisions', $wgLang->formatNum( $result->value ) ); + $nl = wfMsgExt( 'nrevisions', array( 'parsemag', 'escape'), + $wgLang->formatNum( $result->value ) ); $nlink = $skin->makeKnownLinkObj( $nt, $nl, 'action=history' ); return wfSpecialList($plink, $nlink); diff --git a/includes/SpecialPopularpages.php b/includes/SpecialPopularpages.php index e5242c35db..64d6b9842f 100644 --- a/includes/SpecialPopularpages.php +++ b/includes/SpecialPopularpages.php @@ -44,7 +44,8 @@ class PopularPagesPage extends QueryPage { global $wgLang, $wgContLang; $title = Title::makeTitle( $result->namespace, $result->title ); $link = $skin->makeKnownLinkObj( $title, htmlspecialchars( $wgContLang->convert( $title->getPrefixedText() ) ) ); - $nv = wfMsg( "nviews", $wgLang->formatNum( $result->value ) ); + $nv = wfMsgExt( 'nviews', array( 'parsemag', 'escape'), + $wgLang->formatNum( $result->value ) ); return wfSpecialList($link, $nv); } } diff --git a/includes/SpecialWantedcategories.php b/includes/SpecialWantedcategories.php index a1b6d05d3d..6f603d92a1 100644 --- a/includes/SpecialWantedcategories.php +++ b/includes/SpecialWantedcategories.php @@ -68,7 +68,8 @@ class WantedCategoriesPage extends QueryPage { $skin->makeLinkObj( $nt, htmlspecialchars( $text ) ) : $skin->makeBrokenLinkObj( $nt, htmlspecialchars( $text ) ); - $nlinks = wfMsg( 'members', $wgLang->formatNum( $result->value ) ); + $nlinks = wfMsgExt( 'nmembers', array( 'parsemag', 'escape'), + $wgLang->formatNum( $result->value ) ); return wfSpecialList($plink, $nlinks); } } diff --git a/languages/Messages.php b/languages/Messages.php index 9100f4d030..94e4905857 100644 --- a/languages/Messages.php +++ b/languages/Messages.php @@ -235,9 +235,6 @@ See $1.', 'versionrequired' => 'Version $1 of MediaWiki required', 'versionrequiredtext' => 'Version $1 of MediaWiki is required to use this page. See [[Special:Version]]', -'nbytes' => '$1 {{PLURAL:$1|byte|bytes}}', -'ncategories' => '$1 categories', -'nrevisions' => '$1 revisions', 'widthheight' => '$1x$2', 'ok' => 'OK', 'sitetitle' => '{{SITENAME}}', @@ -932,13 +929,19 @@ The [http://meta.wikimedia.org/wiki/Help:Job_queue job queue] length is '''$7''' # Miscellaneous special pages # +'nbytes' => '$1 {{PLURAL:$1|byte|bytes}}', +'ncategories' => '$1 {{PLURAL:$1|category|categories}}', +'nlinks' => '$1 {{PLURAL:$1|link|links}}', +'nmembers' => '$1 {{PLURAL:$1|member|members}}', +'nrevisions' => '$1 {{PLURAL:$1|revision|revisions}}', +'nviews' => '$1 {{PLURAL:$1|view|views}}', + 'lonelypages' => 'Orphaned pages', 'uncategorizedpages' => 'Uncategorized pages', 'uncategorizedcategories' => 'Uncategorized categories', 'unusedcategories' => 'Unused categories', 'unusedimages' => 'Unused files', 'popularpages' => 'Popular pages', -'nviews' => '$1 views', 'wantedcategories' => 'Wanted categories', 'wantedpages' => 'Wanted pages', 'mostlinked' => 'Most linked to pages', @@ -946,8 +949,6 @@ The [http://meta.wikimedia.org/wiki/Help:Job_queue job queue] length is '''$7''' 'mostcategories' => 'Articles with the most categories', 'mostimages' => 'Most linked to images', 'mostrevisions' => 'Articles with the most revisions', -'nlinks' => '$1 {{plural:$1|link|links}}', -'members' => '$1 members', 'allpages' => 'All pages', 'prefixindex' => 'Prefix index', 'randompage' => 'Random page', -- 2.20.1