From eb035f5526d05c47bbaa6c6516d46cc244e50f75 Mon Sep 17 00:00:00 2001 From: Raimond Spekking Date: Fri, 14 Mar 2008 09:04:44 +0000 Subject: [PATCH] * Add a nice fieldset around the input form * Add a CSS id for the table --- includes/SpecialIpblocklist.php | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/includes/SpecialIpblocklist.php b/includes/SpecialIpblocklist.php index 641e1fdde6..5abb6bb711 100644 --- a/includes/SpecialIpblocklist.php +++ b/includes/SpecialIpblocklist.php @@ -76,6 +76,11 @@ class IPUnblockForm { $this->reason = $reason; } + /** + * Generates the unblock form + * @param $err string: error message + * @return $out string: HTML form + */ function showForm( $err ) { global $wgOut, $wgUser, $wgSysopUserBans, $wgContLang; @@ -83,8 +88,6 @@ class IPUnblockForm { $wgOut->addWikiMsg( 'unblockiptext' ); $ipa = wfMsgHtml( $wgSysopUserBans ? 'ipadressorusername' : 'ipaddress' ); - $ipr = wfMsgHtml( 'ipbreason' ); - $ipus = wfMsgHtml( 'ipusubmit' ); $titleObj = SpecialPage::getTitleFor( "Ipblocklist" ); $action = $titleObj->getLocalURL( "action=submit" ); $alignRight = $wgContLang->isRtl() ? 'left' : 'right'; @@ -110,7 +113,9 @@ class IPUnblockForm { $wgOut->addHTML( Xml::openElement( 'form', array( 'method' => 'post', 'action' => $action, 'id' => 'unblockip' ) ) . - Xml::openElement( 'table', array( 'border' => '0' ) ). + Xml::openElement( 'fieldset' ) . + Xml::element( 'legend', null, wfMsg( 'ipb-unblock' ) ) . + Xml::openElement( 'table', array( 'border' => '0', 'id' => 'mw-unblock-table' ) ). " {$ipa} @@ -120,9 +125,9 @@ class IPUnblockForm { - - {$ipr} - + " . + Xml::label( wfMsg( 'ipbreason' ), 'wpUnblockReason' ) . + " " . Xml::input( 'wpUnblockReason', 40, $this->reason, array( 'type' => 'text', 'tabindex' => '2' ) ) . " @@ -130,10 +135,11 @@ class IPUnblockForm {   " . - Xml::submitButton( $ipus, array( 'name' => 'wpBlock', 'tabindex' => '3' ) ) . + Xml::submitButton( wfMsg( 'ipusubmit' ), array( 'name' => 'wpBlock', 'tabindex' => '3' ) ) . " " . Xml::closeElement( 'table' ) . + Xml::closeElement( 'fieldset' ) . Xml::hidden( 'wpEditToken', $token ) . Xml::closeElement( 'form' ) . "\n" ); -- 2.20.1