$ts = $this->getCachedTimestamp();
if ( $ts ) {
- $lang = $this->getLang();
+ $lang = $this->getLanguage();
$updated = $lang->timeanddate( $ts, true, true );
$updateddate = $lang->date( $ts, true, true );
$updatedtime = $lang->time( $ts, true, true );
if ( $this->shownavigation ) {
$out->addHTML( $this->getPageHeader() );
if ( $this->numRows > 0 ) {
- $out->addHTML( '<p>' . wfShowingResults( $this->offset, $this->numRows ) . '</p>' );
+ $out->addHTML( $this->msg( 'showingresults' )->numParams(
+ $this->numRows, $this->offset + 1 )->parseAsBlock() );
# Disable the "next" link when we reach the end
- $paging = wfViewPrevNext( $this->offset, $this->limit,
- $this->getTitle( $par ),
- wfArrayToCGI( $this->linkParameters() ), ( $this->numRows < $this->limit ) );
+ $paging = $this->getLanguage()->viewPrevNext( $this->getTitle( $par ), $this->offset,
+ $this->limit, $this->linkParameters(), ( $this->numRows < $this->limit ) );
$out->addHTML( '<p>' . $paging . '</p>' );
} else {
# No results to show, so don't bother with "showing X of Y" etc.
# -- just let the user know and give up now
- $out->addHTML( '<p>' . wfMsgHtml( 'specialpage-empty' ) . '</p>' );
+ $out->addWikiMsg( 'specialpage-empty' );
$out->addHTML( Xml::closeElement( 'div' ) );
return;
}
}
function feedDesc() {
- return wfMsgExt( 'tagline', 'parsemag' );
+ return $this->msg( 'tagline' )->text();
}
function feedUrl() {
if ( $title instanceof Title ) {
if ( $this->isCached() || $this->forceExistenceCheck() ) {
$pageLink = $title->isKnown()
- ? '<del>' . $skin->link( $title ) . '</del>'
- : $skin->link(
+ ? '<del>' . Linker::link( $title ) . '</del>'
+ : Linker::link(
$title,
null,
array(),
array( 'broken' )
);
} else {
- $pageLink = $skin->link(
+ $pageLink = Linker::link(
$title,
null,
array(),
array( 'broken' )
);
}
- return wfSpecialList( $pageLink, $this->makeWlhLink( $title, $skin, $result ) );
+ return $this->getLanguage()->specialList( $pageLink, $this->makeWlhLink( $title, $result ) );
} else {
- $tsafe = htmlspecialchars( $result->title );
- return wfMsgHtml( 'wantedpages-badtitle', $tsafe );
+ return $this->msg( 'wantedpages-badtitle', $result->title )->escaped();
}
}
* Make a "what links here" link for a given title
*
* @param $title Title to make the link for
- * @param $skin Skin object to use
* @param $result Object: result row
* @return string
*/
- private function makeWlhLink( $title, $skin, $result ) {
- $wlh = SpecialPage::getTitleFor( 'Whatlinkshere' );
- $label = wfMsgExt( 'nlinks', array( 'parsemag', 'escape' ),
- $this->getLang()->formatNum( $result->value ) );
- return $skin->link( $wlh, $label, array(), array( 'target' => $title->getPrefixedText() ) );
+ private function makeWlhLink( $title, $result ) {
+ $wlh = SpecialPage::getTitleFor( 'Whatlinkshere', $title->getPrefixedText() );
+ $label = $this->msg( 'nlinks' )->numParams( $result->value )->escaped();
+ return Linker::link( $wlh, $label );
}
}