* Use browser default for printing size, don't force to 11pt
* (bug 8632) Fix regression in page protection null edit update
* (bug 7842) Link back to deleted revision list from deleted revision preview
+* (bug 8619) Add user-aware "unblock" link to Special:Blockip
== Languages updated ==
* to ensure that client-side caches don't keep obsolete copies of global
* styles.
*/
-$wgStyleVersion = '45';
+$wgStyleVersion = '46';
# Server-side caching:
<input type='hidden' name='wpEditToken' value=\"{$token}\" />
</form>\n" );
+ $wgOut->addHtml( $this->getUnblockLink() );
+
$user = User::newFromName( $this->BlockAddress );
if( is_object( $user ) ) {
$this->showLogFragment( $wgOut, $user->getUserPage() );
return implode( ',', $flags );
}
+ /**
+ * Build a convenient link to unblock the given username or IP
+ * address, if available; otherwise link to a blank unblock
+ * form
+ *
+ * @return string
+ */
+ private function getUnblockLink() {
+ global $wgUser;
+ $list = SpecialPage::getTitleFor( 'Ipblocklist' );
+ $skin = $wgUser->getSkin();
+ if( $this->BlockAddress ) {
+ $addr = htmlspecialchars( $this->BlockAddress );
+ $link = $skin->makeKnownLinkObj( $list, wfMsgHtml( 'ipb-unblock-addr', $addr ),
+ 'action=unblock&ip=' . $addr );
+ } else {
+ $link = $skin->makeKnownLinkObj( $list, wfMsgHtml( 'ipb-unblock' ), 'action=unblock' );
+ }
+ return '<p class="mw-ipb-unblocklink">' . $link . '</p>';
+ }
+
}
?>
'blockipsuccesssub' => 'Block succeeded',
'blockipsuccesstext' => '[[{{ns:Special}}:Contributions/$1|$1]] has been blocked.
<br />See [[{{ns:Special}}:Ipblocklist|IP block list]] to review blocks.',
+'ipb-unblock-addr' => 'Unblock $1',
+'ipb-unblock' => 'Unblock a username or IP address',
'unblockip' => 'Unblock user',
'unblockiptext' => 'Use the form below to restore write access
to a previously blocked IP address or username.',
.templatesUsed { margin-top: 1em; }
+/* "unblock" link on Special:Ipblocklist */
+p.mw-ipb-unblocklink {
+ font-size: 90%;
+ float: right;
+}
+
/**
* Here is some stuff that's ACTUALLY COMMON TO ALL SKINS.
* When the day comes, it can be moved to a *real* common.css.
.mw-summary-preview {
margin: 0.1em 0;
}
+
+/* "unblock" link on Special:Ipblocklist */
+p.mw-ipb-unblocklink {
+ font-size: 90%;
+ float: right;
+}
+
/**
* Here is some stuff that's ACTUALLY COMMON TO ALL SKINS.
* When the day comes, it can be moved to a *real* common.css.