MediaWiki  REL1_23
HTMLInfoField.php
Go to the documentation of this file.
00001 <?php
00002 
00006 class HTMLInfoField extends HTMLFormField {
00007     public function __construct( $info ) {
00008         $info['nodata'] = true;
00009 
00010         parent::__construct( $info );
00011     }
00012 
00013     public function getInputHTML( $value ) {
00014         return !empty( $this->mParams['raw'] ) ? $value : htmlspecialchars( $value );
00015     }
00016 
00017     public function getTableRow( $value ) {
00018         if ( !empty( $this->mParams['rawrow'] ) ) {
00019             return $value;
00020         }
00021 
00022         return parent::getTableRow( $value );
00023     }
00024 
00028     public function getDiv( $value ) {
00029         if ( !empty( $this->mParams['rawrow'] ) ) {
00030             return $value;
00031         }
00032 
00033         return parent::getDiv( $value );
00034     }
00035 
00039     public function getRaw( $value ) {
00040         if ( !empty( $this->mParams['rawrow'] ) ) {
00041             return $value;
00042         }
00043 
00044         return parent::getRaw( $value );
00045     }
00046 
00047     protected function needsLabel() {
00048         return false;
00049     }
00050 }