Expose $wgMaxArticleSize in siteinfo query api
[mediawiki.git] / includes / htmlform / HTMLSelectNamespace.php
blobef219690fd8a8ed467469672806de98a0529d7aa
1 <?php
2 /**
3 * Wrapper for Html::namespaceSelector to use in HTMLForm
4 */
5 class HTMLSelectNamespace extends HTMLFormField {
6 public function __construct( $params ) {
7 parent::__construct( $params );
9 $this->mAllValue = array_key_exists( 'all', $params )
10 ? $params['all']
11 : 'all';
15 function getInputHTML( $value ) {
16 return Html::namespaceSelector(
18 'selected' => $value,
19 'all' => $this->mAllValue
20 ], [
21 'name' => $this->mName,
22 'id' => $this->mID,
23 'class' => 'namespaceselector',
28 public function getInputOOUI( $value ) {
29 return new MediaWiki\Widget\NamespaceInputWidget( [
30 'value' => $value,
31 'name' => $this->mName,
32 'id' => $this->mID,
33 'includeAllValue' => $this->mAllValue,
34 ] );