Index: trunk/phase3/includes/specials/SpecialMostcategories.php |
— | — | @@ -58,11 +58,10 @@ |
59 | 59 | * @return string |
60 | 60 | */ |
61 | 61 | function formatResult( $skin, $result ) { |
62 | | - global $wgLang; |
63 | 62 | $title = Title::makeTitleSafe( $result->namespace, $result->title ); |
64 | 63 | |
65 | | - $count = wfMsgExt( 'ncategories', array( 'parsemag', 'escape' ), $wgLang->formatNum( $result->value ) ); |
66 | | - $link = $skin->link( $title ); |
| 64 | + $count = $this->msg( 'ncategories' )->numParams( $result->value )->escaped(); |
| 65 | + $link = Linker::link( $title ); |
67 | 66 | return wfSpecialList( $link, $count ); |
68 | 67 | } |
69 | 68 | } |
Index: trunk/phase3/includes/specials/SpecialMostimages.php |
— | — | @@ -50,9 +50,7 @@ |
51 | 51 | } |
52 | 52 | |
53 | 53 | function getCellHtml( $row ) { |
54 | | - global $wgLang; |
55 | | - return wfMsgExt( 'nimagelinks', array( 'parsemag', 'escape' ), |
56 | | - $wgLang->formatNum( $row->value ) ) . '<br />'; |
| 54 | + return $this->msg( 'nimagelinks' )->numParams( $row->value )->escaped() . '<br />'; |
57 | 55 | } |
58 | 56 | |
59 | 57 | } |
Index: trunk/phase3/includes/specials/SpecialMostlinkedtemplates.php |
— | — | @@ -99,8 +99,8 @@ |
100 | 100 | $title = Title::makeTitle( $result->namespace, $result->title ); |
101 | 101 | |
102 | 102 | return wfSpecialList( |
103 | | - $skin->link( $title ), |
104 | | - $this->makeWlhLink( $title, $skin, $result ) |
| 103 | + Linker::link( $title ), |
| 104 | + $this->makeWlhLink( $title, $result ) |
105 | 105 | ); |
106 | 106 | } |
107 | 107 | |
— | — | @@ -108,16 +108,13 @@ |
109 | 109 | * Make a "what links here" link for a given title |
110 | 110 | * |
111 | 111 | * @param $title Title to make the link for |
112 | | - * @param $skin Skin to use |
113 | 112 | * @param $result Result row |
114 | 113 | * @return String |
115 | 114 | */ |
116 | | - private function makeWlhLink( $title, $skin, $result ) { |
117 | | - global $wgLang; |
118 | | - $wlh = SpecialPage::getTitleFor( 'Whatlinkshere' ); |
119 | | - $label = wfMsgExt( 'ntransclusions', array( 'parsemag', 'escape' ), |
120 | | - $wgLang->formatNum( $result->value ) ); |
121 | | - return $skin->link( $wlh, $label, array(), array( 'target' => $title->getPrefixedText() ) ); |
| 115 | + private function makeWlhLink( $title, $result ) { |
| 116 | + $wlh = SpecialPage::getTitleFor( 'Whatlinkshere', $title->getPrefixedText() ); |
| 117 | + $label = $this->msg( 'ntransclusions' )->numParams( $result->value )->escaped(); |
| 118 | + return Linker::link( $wlh, $label ); |
122 | 119 | } |
123 | 120 | } |
124 | 121 | |
Index: trunk/phase3/includes/specials/SpecialMostlinked.php |
— | — | @@ -77,12 +77,11 @@ |
78 | 78 | * |
79 | 79 | * @param $title Title being queried |
80 | 80 | * @param $caption String: text to display on the link |
81 | | - * @param $skin Skin to use |
82 | 81 | * @return String |
83 | 82 | */ |
84 | | - function makeWlhLink( &$title, $caption, &$skin ) { |
| 83 | + function makeWlhLink( $title, $caption ) { |
85 | 84 | $wlh = SpecialPage::getTitleFor( 'Whatlinkshere', $title->getPrefixedDBkey() ); |
86 | | - return $skin->linkKnown( $wlh, $caption ); |
| 85 | + return Linker::linkKnown( $wlh, $caption ); |
87 | 86 | } |
88 | 87 | |
89 | 88 | /** |
— | — | @@ -93,15 +92,13 @@ |
94 | 93 | * @return string |
95 | 94 | */ |
96 | 95 | function formatResult( $skin, $result ) { |
97 | | - global $wgLang; |
98 | 96 | $title = Title::makeTitleSafe( $result->namespace, $result->title ); |
99 | 97 | if ( !$title ) { |
100 | 98 | return '<!-- ' . htmlspecialchars( "Invalid title: [[$title]]" ) . ' -->'; |
101 | 99 | } |
102 | | - $link = $skin->link( $title ); |
| 100 | + $link = Linker::link( $title ); |
103 | 101 | $wlh = $this->makeWlhLink( $title, |
104 | | - wfMsgExt( 'nlinks', array( 'parsemag', 'escape'), |
105 | | - $wgLang->formatNum( $result->value ) ), $skin ); |
| 102 | + $this->msg( 'nlinks' )->numParams( $result->value )->escaped() ); |
106 | 103 | return wfSpecialList( $link, $wlh ); |
107 | 104 | } |
108 | 105 | } |
Index: trunk/phase3/includes/specials/SpecialMostlinkedcategories.php |
— | — | @@ -76,15 +76,14 @@ |
77 | 77 | * @return string |
78 | 78 | */ |
79 | 79 | function formatResult( $skin, $result ) { |
80 | | - global $wgLang, $wgContLang; |
| 80 | + global $wgContLang; |
81 | 81 | |
82 | 82 | $nt = Title::makeTitle( NS_CATEGORY, $result->title ); |
83 | 83 | $text = $wgContLang->convert( $nt->getText() ); |
84 | 84 | |
85 | | - $plink = $skin->link( $nt, htmlspecialchars( $text ) ); |
| 85 | + $plink = Linker::link( $nt, htmlspecialchars( $text ) ); |
86 | 86 | |
87 | | - $nlinks = wfMsgExt( 'nmembers', array( 'parsemag', 'escape' ), |
88 | | - $wgLang->formatNum( $result->value ) ); |
| 87 | + $nlinks = $this->msg( 'nmembers' )->numParams( $result->value )->escaped(); |
89 | 88 | return wfSpecialList( $plink, $nlinks ); |
90 | 89 | } |
91 | 90 | } |