r14224 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r14223‎ | r14224 | r14225 >
Date:17:44, 14 May 2006
Author:nikerabbit
Status:old
Tags:
Comment:
* plural support for nlinks
Modified paths:
  • /trunk/phase3/includes/SpecialMostimages.php (modified) (history)
  • /trunk/phase3/includes/SpecialMostlinked.php (modified) (history)
  • /trunk/phase3/includes/SpecialWantedpages.php (modified) (history)
  • /trunk/phase3/languages/Messages.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/SpecialMostimages.php
@@ -45,7 +45,8 @@
4646
4747 $plink = $skin->makeKnownLink( $nt->getPrefixedText(), $text );
4848
49 - $nl = wfMsg( 'nlinks', $wgLang->formatNum ( $result->value ) );
 49+ $nl = wfMsgExt( 'nlinks', array( 'parsemag', 'escape'),
 50+ $wgLang->formatNum ( $result->value ) );
5051 $nlink = $skin->makeKnownLink( $nt->getPrefixedText() . '#filelinks', $nl );
5152
5253 return wfSpecialList($plink, $nlink);
Index: trunk/phase3/includes/SpecialMostlinked.php
@@ -80,8 +80,9 @@
8181 global $wgLang;
8282 $title = Title::makeTitleSafe( $result->namespace, $result->title );
8383 $link = $skin->makeLinkObj( $title );
84 - $wlh = $this->makeWlhLink( $title, wfMsgHtml( 'nlinks',
85 - $wgLang->formatNum( $result->value ) ), $skin );
 84+ $wlh = $this->makeWlhLink( $title,
 85+ wfMsgExt( 'nlinks', array( 'parsemag', 'escape'),
 86+ $wgLang->formatNum( $result->value ) ), $skin );
8687 return wfSpecialList( $link, $wlh );
8788 }
8889 }
Index: trunk/phase3/includes/SpecialWantedpages.php
@@ -92,8 +92,9 @@
9393
9494 # Make a link to "what links here" if it's required
9595 $wlhLink = $this->nlinks
96 - ? $this->makeWlhLink( $title, $skin, wfMsgHtml( 'nlinks',
97 - $wgLang->formatNum( $result->value ) ) )
 96+ ? $this->makeWlhLink( $title, $skin,
 97+ wfMsgExt( 'nlinks', array( 'parsemag', 'escape'),
 98+ $wgLang->formatNum( $result->value ) ) )
9899 : null;
99100
100101 return wfSpecialList($pageLink, $wlhLink);
Index: trunk/phase3/languages/Messages.php
@@ -946,7 +946,7 @@
947947 'mostcategories' => 'Articles with the most categories',
948948 'mostimages' => 'Most linked to images',
949949 'mostrevisions' => 'Articles with the most revisions',
950 -'nlinks' => '$1 links',
 950+'nlinks' => '$1 {{plural:$1|link|links}}',
951951 'members' => '$1 members',
952952 'allpages' => 'All pages',
953953 'prefixindex' => 'Prefix index',

Status & tagging log