# Anons don't get a watchlist
if( $user->isAnon() ) {
- $output->setPageTitleMsg( 'watchnologin' );
+ $output->setPageTitle( $this->msg( 'watchnologin' ) );
$llink = Linker::linkKnown(
SpecialPage::getTitleFor( 'Userlogin' ),
wfMsgHtml( 'loginreqlink' ),
$this->setHeaders();
$this->outputHeader();
- $sub = wfMsgExt(
- 'watchlistfor2',
- array( 'parseinline', 'replaceafter' ),
- $user->getName(),
- SpecialEditWatchlist::buildTools( $this->getSkin() )
- );
- $output->setSubtitle( $sub );
+ $output->addSubtitle( $this->msg( 'watchlistfor2', $this->getUser()->getName()
+ )->rawParams( SpecialEditWatchlist::buildTools( null ) ) );
$request = $this->getRequest();
$output->showLagWarning( $lag );
}
- $lang = $this->getLang();
+ $lang = $this->getLanguage();
# Create output form
$form = Xml::fieldset( wfMsg( 'watchlist-options' ), false, array( 'id' => 'mw-watchlist-options' ) );
/* Start bottom header */
$wlInfo = '';
- if( $values['days'] >= 1 ) {
+ if( $values['days'] > 0 ) {
$timestamp = wfTimestampNow();
- $wlInfo = wfMsgExt( 'rcnote', 'parseinline',
+ $wlInfo = wfMsgExt( 'wlnote', 'parseinline',
$lang->formatNum( $numRows ),
- $lang->formatNum( $values['days'] ),
- $lang->timeAndDate( $timestamp, true ),
+ $lang->formatNum( round( $values['days'] * 24 ) ),
$lang->date( $timestamp, true ),
$lang->time( $timestamp, true )
) . '<br />';
- } elseif( $values['days'] > 0 ) {
- $wlInfo = wfMsgExt( 'wlnote', 'parseinline',
- $lang->formatNum( $numRows ),
- $lang->formatNum( round( $values['days'] * 24 ) )
- ) . '<br />';
}
$cutofflinks = "\n" . $this->cutoffLinks( $values['days'], $nondefaults ) . "<br />\n";
return Linker::linkKnown(
$this->getTitle(),
- $this->getLang()->formatNum( $h ),
+ $this->getLanguage()->formatNum( $h ),
array(),
$options
);
protected function daysLink( $d, $options = array() ) {
$options['days'] = $d;
- $message = ( $d ? $this->getLang()->formatNum( $d ) : wfMsgHtml( 'watchlistall2' ) );
+ $message = ( $d ? $this->getLanguage()->formatNum( $d ) : wfMsgHtml( 'watchlistall2' ) );
return Linker::linkKnown(
$this->getTitle(),
}
return wfMsgExt('wlshowlast',
array('parseinline', 'replaceafter'),
- $this->getLang()->pipeList( $hours ),
- $this->getLang()->pipeList( $days ),
+ $this->getLanguage()->pipeList( $hours ),
+ $this->getLanguage()->pipeList( $days ),
$this->daysLink( 0, $options ) );
}