[ Index ]

PHP Cross Reference of MediaWiki-1.24.0

title

Body

[close]

/includes/htmlform/ -> HTMLHiddenField.php (source)

   1  <?php
   2  
   3  class HTMLHiddenField extends HTMLFormField {
   4  	public function __construct( $params ) {
   5          parent::__construct( $params );
   6  
   7          # Per HTML5 spec, hidden fields cannot be 'required'
   8          # http://www.w3.org/TR/html5/forms.html#hidden-state-%28type=hidden%29
   9          unset( $this->mParams['required'] );
  10      }
  11  
  12  	public function getTableRow( $value ) {
  13          $params = array();
  14          if ( $this->mID ) {
  15              $params['id'] = $this->mID;
  16          }
  17  
  18          $this->mParent->addHiddenField( $this->mName, $this->mDefault, $params );
  19  
  20          return '';
  21      }
  22  
  23      /**
  24       * @param string $value
  25       * @return string
  26       * @since 1.20
  27       */
  28  	public function getDiv( $value ) {
  29          return $this->getTableRow( $value );
  30      }
  31  
  32      /**
  33       * @param string $value
  34       * @return string
  35       * @since 1.20
  36       */
  37  	public function getRaw( $value ) {
  38          return $this->getTableRow( $value );
  39      }
  40  
  41  	public function getInputHTML( $value ) {
  42          return '';
  43      }
  44  }


Generated: Fri Nov 28 14:03:12 2014 Cross-referenced by PHPXref 0.7.1