r49919 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r49918‎ | r49919 | r49920 >
Date:00:55, 27 April 2009
Author:werdna
Status:ok
Tags:
Comment:
Fix display of inverted check fields in HTML forms -- fixes bug 18581.
Modified paths:
  • /trunk/phase3/includes/HTMLForm.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/HTMLForm.php
@@ -525,6 +525,9 @@
526526
527527 class HTMLCheckField extends HTMLFormField {
528528 function getInputHTML( $value ) {
 529+ if ( !empty( $this->mParams['invert'] ) )
 530+ $value = !$value;
 531+
529532 return Xml::check( $this->mName, $value, array( 'id' => $this->mID ) ) . ' ' .
530533 Xml::tags( 'label', array( 'for' => $this->mID ), $this->mLabel );
531534 }

Status & tagging log