From c14edb62716617b87790436f06b3144c4cc1d5ed Mon Sep 17 00:00:00 2001 From: ayush_garg Date: Wed, 11 Feb 2015 16:43:26 +0530 Subject: [PATCH] Export: Preloading the category name through a URL parameter Bug: T88683 Change-Id: Iff7d4c1e7138c5160dbaa7b2455695837026d6c1 --- includes/specials/SpecialExport.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/includes/specials/SpecialExport.php b/includes/specials/SpecialExport.php index 38c52a0178..c30d962a99 100644 --- a/includes/specials/SpecialExport.php +++ b/includes/specials/SpecialExport.php @@ -182,13 +182,20 @@ class SpecialExport extends SpecialPage { $out = $this->getOutput(); $out->addWikiMsg( 'exporttext' ); + if ( $page == '' ) { + $categoryName = $request->getText( 'catname' ); + } else { + $categoryName = ''; + } + $form = Xml::openElement( 'form', array( 'method' => 'post', 'action' => $this->getPageTitle()->getLocalURL( 'action=submit' ) ) ); $form .= Xml::inputLabel( $this->msg( 'export-addcattext' )->text(), 'catname', 'catname', - 40 + 40, + $categoryName ) . ' '; $form .= Xml::submitButton( $this->msg( 'export-addcat' )->text(), -- 2.20.1