MediaWiki  1.23.2
HTMLButtonField.php
Go to the documentation of this file.
1 <?php
2 
11  protected $buttonType = 'button';
12 
13  public function __construct( $info ) {
14  $info['nodata'] = true;
15  parent::__construct( $info );
16  }
17 
18  public function getInputHTML( $value ) {
19  $attr = array(
20  'class' => 'mw-htmlform-submit ' . $this->mClass,
21  'id' => $this->mID,
22  ) + $this->getAttributes( array( 'disabled', 'tabindex' ) );
23 
24  return Html::input( $this->mName, $value, $this->buttonType, $attr );
25  }
26 
27  protected function needsLabel() {
28  return false;
29  }
30 
39  public function validate( $value, $alldata ) {
40  return true;
41  }
42 }
HTMLButtonField\needsLabel
needsLabel()
Should this field have a label, or is there no input element with the appropriate id for the label to...
Definition: HTMLButtonField.php:27
HTMLButtonField\__construct
__construct( $info)
Initialise the object.
Definition: HTMLButtonField.php:13
HTMLButtonField\validate
validate( $value, $alldata)
Button cannot be invalid.
Definition: HTMLButtonField.php:39
php
skin txt MediaWiki includes four core it has been set as the default in MediaWiki since the replacing Monobook it had been been the default skin since before being replaced by Vector largely rewritten in while keeping its appearance Several legacy skins were removed in the as the burden of supporting them became too heavy to bear Those in etc for skin dependent CSS etc for skin dependent JavaScript These can also be customised on a per user by etc This feature has led to a wide variety of user styles becoming that gallery is a good place to ending in php
Definition: skin.txt:62
HTMLButtonField
Adds a generic button inline to the form.
Definition: HTMLButtonField.php:10
HTMLFormField
The parent class to generate form fields.
Definition: HTMLFormField.php:7
array
the array() calling protocol came about after MediaWiki 1.4rc1.
List of Api Query prop modules.
Html\input
static input( $name, $value='', $type='text', $attribs=array())
Convenience function to produce an "<input>" element.
Definition: Html.php:645
$value
$value
Definition: styleTest.css.php:45
HTMLButtonField\getInputHTML
getInputHTML( $value)
This function must be implemented to return the HTML to generate the input object itself.
Definition: HTMLButtonField.php:18
HTMLButtonField\$buttonType
$buttonType
Definition: HTMLButtonField.php:11
HTMLFormField\getAttributes
getAttributes(array $list)
Returns the given attributes from the parameters.
Definition: HTMLFormField.php:493