From: John Du Hart Date: Sun, 27 Nov 2011 19:17:07 +0000 (+0000) Subject: Followup r104353, updating Special:Categories X-Git-Tag: 1.31.0-rc.0~26264 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/?a=commitdiff_plain;h=2789087b3c34f71d6a5775648d08f603be2549da;p=lhc%2Fweb%2Fwiklou.git Followup r104353, updating Special:Categories --- diff --git a/includes/specials/SpecialCategories.php b/includes/specials/SpecialCategories.php index 6d2831c7b0..ee973c02aa 100644 --- a/includes/specials/SpecialCategories.php +++ b/includes/specials/SpecialCategories.php @@ -35,7 +35,7 @@ class SpecialCategories extends SpecialPage { $this->outputHeader(); $this->getOutput()->allowClickjacking(); - $from = $this->getRequest()->getText( 'from', $par ); + $from = $this->getRequest()->getText( 'wpFrom', $par ); $cap = new CategoryPager( $this->getContext(), $from ); $cap->doQuery(); @@ -43,7 +43,7 @@ class SpecialCategories extends SpecialPage { $this->getOutput()->addHTML( Html::openElement( 'div', array( 'class' => 'mw-spcontent' ) ) . $this->msg( 'categoriespagetext', $cap->getNumRows() )->parseAsBlock() . - $cap->getStartForm( $from ) . + $cap->buildHTMLForm() . $cap->getNavigationBar() . '' . $cap->getNavigationBar() . @@ -118,16 +118,21 @@ class CategoryPager extends AlphabeticPager { return Xml::tags( 'li', null, $this->getLanguage()->specialList( $titleText, $count ) ) . "\n"; } - public function getStartForm( $from ) { - global $wgScript; - - return - Xml::tags( 'form', array( 'method' => 'get', 'action' => $wgScript ), - Html::hidden( 'title', $this->getTitle()->getPrefixedText() ) . - Xml::fieldset( $this->msg( 'categories' )->text(), - Xml::inputLabel( $this->msg( 'categoriesfrom' )->text(), - 'from', 'from', 20, $from ) . - ' ' . - Xml::submitButton( $this->msg( 'allpagessubmit' )->text() ) ) ); + protected function getHTMLFormFields() { + return array( + 'From' => array( + 'type' => 'text', + 'label-message' => 'categoriesfrom', + 'size' => '20', + ), + ); + } + + protected function getHTMLFormLegend() { + return 'categories'; + } + + protected function getHTMLFormSubmit() { + return 'allpagessubmit'; } }