* Take out some hard coded pipe characters. Replace by message or Language::pipeList
* Take out a hard coded comma list SpecialIpblocklist.php. Replace by Language::commaList
} else {
$nlink = '<a href="' . $title->escapeLocalUrl( $q ) . "\" class=\"mw-nextlink\">{$next}</a>";
}
- $nums = wfNumLink( $offset, 20, $title, $query ) . ' | ' .
- wfNumLink( $offset, 50, $title, $query ) . ' | ' .
- wfNumLink( $offset, 100, $title, $query ) . ' | ' .
- wfNumLink( $offset, 250, $title, $query ) . ' | ' .
- wfNumLink( $offset, 500, $title, $query );
+ $nums = $wgLang->pipeList( wfNumLink( $offset, 20, $title, $query ),
+ wfNumLink( $offset, 50, $title, $query ),
+ wfNumLink( $offset, 100, $title, $query ),
+ wfNumLink( $offset, 250, $title, $query ),
+ wfNumLink( $offset, 500, $title, $query ) );
return wfMsg( 'viewprevnext', $plink, $nlink, $nums );
}
* @return string
*/
public function userToolLinks( $userId, $userText, $redContribsWhenNoEdits = false, $flags = 0, $edits=null ) {
- global $wgUser, $wgDisableAnonTalk, $wgSysopUserBans;
+ global $wgUser, $wgDisableAnonTalk, $wgSysopUserBans, $wgLang;
$talkable = !( $wgDisableAnonTalk && 0 == $userId );
$blockable = ( $wgSysopUserBans || 0 == $userId ) && !$flags & self::TOOL_LINKS_NOBLOCK;
}
if( $items ) {
- return ' <span class="mw-usertoollinks">(' . implode( ' | ', $items ) . ')</span>';
+ return ' <span class="mw-usertoollinks">(' . $wgLang->pipeList( $items ) . ')</span>';
} else {
return '';
}
array(),
array( 'action' => 'unblock', 'ip' => $row->log_title ),
'known' )
- . ' ' . $this->message['pipe-separator'] . ' ' .
+ . $this->message['pipe-separator'] .
$this->skin->link( SpecialPage::getTitleFor( 'Blockip', $row->log_title ),
$this->message['change-blocklink'],
array(), array(), 'known' ) .
array(),
array( 'action' => 'history', 'offset' => $row->log_timestamp ) );
if( $wgUser->isAllowed( 'protect' ) ) {
- $revert .= ' ' . $this->message['pipe-separator'] . ' ' .
+ $revert .= $this->message['pipe-separator'] .
$this->skin->link( $title,
$this->message['protect_change'],
array(),
}
if( $tools ) {
- $s .= ' (' . implode( ' | ', $tools ) . ')';
+ $s .= ' (' . $wgLang->pipeList( $tools ) . ')';
}
# Tags
$pagingLinks = $this->getPagingLinks( $linkTexts );
$limitLinks = $this->getLimitLinks();
- $limits = implode( ' | ', $limitLinks );
+ $limits = $wgLang->pipeList( $limitLinks );
$this->mNavigationBar =
"({$pagingLinks['first']} | {$pagingLinks['last']}) " .
if( $first ) {
$first = false;
} else {
- $extra .= ' | ';
+ $extra .= wfMsgExt( 'pipe-separator' , 'escapenoentities' );
}
if( $order == $this->mOrderType ) {
$pagingLinks = $this->getPagingLinks( $linkTexts );
$limitLinks = $this->getLimitLinks();
- $limits = implode( ' | ', $limitLinks );
+ $limits = $wgLang->pipeList( $limitLinks );
- $this->mNavigationBar = "({$pagingLinks['first']} | {$pagingLinks['last']}) " .
+ $this->mNavigationBar = "({$pagingLinks['first']}" . wfMsgExt( 'pipe-separator' , 'escapenoentities' ) . "{$pagingLinks['last']}) " .
wfMsgHtml("viewprevnext", $pagingLinks['prev'], $pagingLinks['next'], $limits);
return $this->mNavigationBar;
}
}
function searchForm() {
- global $wgTitle, $wgScript, $wgRequest;
+ global $wgTitle, $wgScript, $wgRequest, $wgLang;
$showhide = array( wfMsg( 'show' ), wfMsg( 'hide' ) );
$nondefaults = array();
$links[] = wfMsgHtml( 'ipblocklist-sh-userblocks', $ubLink );
$links[] = wfMsgHtml( 'ipblocklist-sh-tempblocks', $tbLink );
$links[] = wfMsgHtml( 'ipblocklist-sh-addressblocks', $sipbLink );
- $hl = implode( ' ' . wfMsg( 'pipe-separator' ) . ' ', $links );
+ $hl = $wgLang->pipeList( $links );
return
Xml::tags( 'form', array( 'action' => $wgScript ),
$properties[] = $msg['blocklist-nousertalk'];
}
- $properties = implode( ', ', $properties );
+ $properties = $wgLang->commaList( $properties );
$line = wfMsgReplaceArgs( $msg['blocklistline'], array( $formattedTime, $blocker, $target, $properties ) );
# Create changeblocklink for all blocks with exception of autoblocks
if( !$block->mAuto ) {
- $changeblocklink = ' ' . wfMsg( 'pipe-separator' ) . ' ' .
+ $changeblocklink = wfMsg( 'pipe-separator' ) .
$sk->link( SpecialPage::getTitleFor( 'Blockip', $block->mAddress ),
$msg['change-blocklink'],
array(), array(), 'known' );
'comma-separator' => ', ', # only translate this message to other languages if you have to change it
'colon-separator' => ': ', # only translate this message to other languages if you have to change it
'autocomment-prefix' => '- ', # only translate this message to other languages if you have to change it
-'pipe-separator' => '|', # only translate this message to other languages if you have to change it
+'pipe-separator' => ' | ', # only translate this message to other languages if you have to change it
'word-separator' => ' ', # only translate this message to other languages if you have to change it
'ellipsis' => '…', # only translate this message to other languages if you have to change it
# Separators for various lists, etc.
'colon-separator' => ' : ',
'autocomment-prefix' => '-',
-'pipe-separator' => '•',
+'pipe-separator' => ' • ',
# Multipage image navigation
'imgmultipageprev' => '← pagina precedenta',