From c2fef865622a3b7c422376e6077069ca868ea604 Mon Sep 17 00:00:00 2001 From: Raimond Spekking Date: Tue, 18 Mar 2008 15:31:55 +0000 Subject: [PATCH] * Add a nice fieldset around the input form * Use proper XML function --- includes/SpecialFilepath.php | 39 ++++++++---------------------------- 1 file changed, 8 insertions(+), 31 deletions(-) diff --git a/includes/SpecialFilepath.php b/includes/SpecialFilepath.php index 4ba8fdb032..84412ab616 100644 --- a/includes/SpecialFilepath.php +++ b/includes/SpecialFilepath.php @@ -33,37 +33,14 @@ class FilepathForm { global $wgOut, $wgTitle, $wgScript; $wgOut->addHTML( - wfElement( 'form', - array( - 'id' => 'specialfilepath', - 'method' => 'get', - 'action' => $wgScript, - ), - null - ) . - wfHidden( 'title', $wgTitle->getPrefixedText() ) . - wfOpenElement( 'label' ) . - wfMsgHtml( 'filepath-page' ) . - ' ' . - wfElement( 'input', - array( - 'type' => 'text', - 'size' => 25, - 'name' => 'file', - 'value' => is_object( $this->mTitle ) ? $this->mTitle->getText() : '' - ), - '' - ) . - ' ' . - wfElement( 'input', - array( - 'type' => 'submit', - 'value' => wfMsgHtml( 'filepath-submit' ) - ), - '' - ) . - wfCloseElement( 'label' ) . - wfCloseElement( 'form' ) + Xml::openElement( 'form', array( 'method' => 'get', 'action' => $wgScript, 'id' => 'specialfilepath' ) ) . + Xml::openElement( 'fieldset' ) . + Xml::element( 'legend', null, wfMsg( 'filepath' ) ) . + Xml::hidden( 'title', $wgTitle->getPrefixedText() ) . + Xml::inputLabel( wfMsg( 'filepath-page' ), 'file', 'file', 25, is_object( $this->mTitle ) ? $this->mTitle->getText() : '' ) . ' ' . + Xml::submitButton( wfMsg( 'filepath-submit' ) ) . "\n" . + Xml::closeElement( 'fieldset' ) . + Xml::closeElement( 'form' ) ); } } -- 2.20.1