Debian Codegraph @

includes/htmlform/fields/HTMLSubmitField.php

raw symbols SCIP
1 <?php
2
3 namespace MediaWiki\HTMLForm\Field;
4
5 /**
6 * Add a submit button inline in the form (as opposed to
7 * HTMLForm::addButton(), which will add it at the end).
8 *
9 * @stable to extend
10 */
11 class HTMLSubmitField extends HTMLButtonField {
12 /** @inheritDoc */
13 protected $buttonType = 'submit';
14
15 /** @inheritDoc */
16 protected $mFlags = [ 'primary', 'progressive' ];
17
18 public function skipLoadData( $request ) {
19 return !$request->getCheck( $this->mName );
20 }
21
22 public function loadDataFromRequest( $request ) {
23 return $request->getCheck( $this->mName );
24 }
25 }
26
27 /** @deprecated class alias since 1.42 */
28 class_alias( HTMLSubmitField::class, 'HTMLSubmitField' );