if( !$r )
$r = $user->getRestrictionForNamespace( $this->getNamespace() );
if( $r ) {
- $start = $wgLang->timeanddate( $r->getTimestamp() );
- $end = $r->getExpiry() == 'infinity' ?
- wfMsg( 'ipbinfinite' ) :
- $wgLang->timeanddate( $r->getExpiry() );
+ $error = array();
+ $start = array( $wgLang->date( $r->getTimestamp() ), $wgLang->time( $r->getTimestamp() ) );
if( $r->isPage() )
- $errors[] = array( 'userrestricted-page', $this->getFullText(),
- $r->getBlockerText(), $r->getReason(), $start, $end );
- elseif( $r->isNamespace() ) {
- $errors[] = array( 'userrestricted-namespace', $wgLang->getDisplayNsText( $this->getNamespace() ),
- $r->getBlockerText(), $r->getReason(), $start, $end );
+ $error = array( 'userrestricted-page', $this->getFullText(),
+ $r->getBlockerText(), $r->getReason(), $start[0], $start[1] );
+ elseif( $r->isNamespace() )
+ $error = array( 'userrestricted-namespace', $wgLang->getDisplayNsText( $this->getNamespace() ),
+ $r->getBlockerText(), $r->getReason(), $start[0], $start[1] );
+
+ if( $r->getExpiry() == 'infinity' ) {
+ $error[0] .= '-indef';
+ } else {
+ $error[] = $wgLang->date( $r->getExpiry() );
+ $error[] = $wgLang->time( $r->getExpiry() );
}
+ $errors[] = $error;
}
}
$subjlink = $sk->userLink( $r->getSubjectId(), $r->getSubjectText() ) .
$sk->userToolLinks( $r->getSubjectId(), $r->getSubjectText() );
$expiry = is_numeric( $r->getExpiry() ) ?
- wfMsg( 'listuserrestrictions-row-expiry', $wgLang->timeanddate( $r->getExpiry() ) ) :
+ wfMsg( 'listuserrestrictions-row-expiry', $wgLang->date( $r->getExpiry() ), $wgLang->time( $r->getExpiry() ) ) :
wfMsg( 'ipbinfinite' );
$msg = '';
if( $r->isNamespace() ) {
The restriction was put by [[User:$2|$2]].
The reason given is \'\'$3\'\'.
-Restriction was put at $4 and expires at $5.
+Restriction was put on $4 at $5 and expires on $6 at $7.
You can contact [[User:$2|$2]] or another [[{{MediaWiki:Grouppage-sysop}}|administrator]] to discuss the restriction.',
'userrestricted-namespace' => "<big>'''Your user name or IP address has been restricted from editing $1 namespace.'''</big>
The restriction was put by [[User:$2|$2]].
The reason given is ''$3''.
-Restriction was put at $4 and expires at $5.
+Restriction was put on $4 at $5 and expires on $6 at $7.
+
+You can contact [[User:$2|$2]] or another [[{{MediaWiki:Grouppage-sysop}}|administrator]] to discuss the restriction.",
+'userrestricted-page-indef' => '<big>\'\'\'Your user name or IP address has been restricted from editing page "$1".\'\'\'</big>
+
+The restriction was put by [[User:$2|$2]].
+The reason given is \'\'$3\'\'.
+
+Restriction was put at $4 and will not expire.
+
+You can contact [[User:$2|$2]] or another [[{{MediaWiki:Grouppage-sysop}}|administrator]] to discuss the restriction.',
+'userrestricted-namespace-indef' => "<big>'''Your user name or IP address has been restricted from editing $1 namespace.'''</big>
+
+The restriction was put by [[User:$2|$2]].
+The reason given is ''$3''.
+
+Restriction was put at $4 and will not expire.
You can contact [[User:$2|$2]] or another [[{{MediaWiki:Grouppage-sysop}}|administrator]] to discuss the restriction.",
[[Special:Ipblocklist|Blocks]] are not listed here.',
'listuserrestrictions-row-ns' => 'restricted $1 from editing $2 namespace ($3)',
'listuserrestrictions-row-page' => 'restricted $1 from editing $2 ($3)',
-'listuserrestrictions-row-expiry' => 'expires at $1',
+'listuserrestrictions-row-expiry' => 'expires on $1 at $2',
'listuserrestrictions-legend' => 'Find a restriction',
'listuserrestrictions-type' => 'Type:',
'listuserrestrictions-user' => 'User:',