Index: trunk/phase3/includes/HTMLForm.php |
— | — | @@ -717,7 +717,7 @@ |
718 | 718 | static $jsAdded = false; |
719 | 719 | |
720 | 720 | function __construct( $params ) { |
721 | | - if( !in_array( 'other', $params['options'] ) ) { |
| 721 | + if( !in_array( 'other', $params['options'], true ) ) { |
722 | 722 | $params['options'][wfMsg( 'htmlform-selectorother-other' )] = 'other'; |
723 | 723 | } |
724 | 724 | |
— | — | @@ -748,7 +748,7 @@ |
749 | 749 | |
750 | 750 | $select->setAttribute( 'class', 'mw-htmlform-select-or-other' ); |
751 | 751 | |
752 | | - $tbAttribs = array( 'id' => $this->mID . '-other' ); |
| 752 | + $tbAttribs = array( 'id' => $this->mID . '-other', 'size' => $this->getSize() ); |
753 | 753 | if( !empty( $this->mParams['disabled'] ) ) { |
754 | 754 | $select->setAttribute( 'disabled', 'disabled' ); |
755 | 755 | $tbAttribs['disabled'] = 'disabled'; |
— | — | @@ -761,8 +761,8 @@ |
762 | 762 | } |
763 | 763 | |
764 | 764 | $textbox = Html::input( $this->mName . '-other', |
765 | | - $this->getSize(), |
766 | | - $valInSelect ? 'text' : $value, |
| 765 | + $valInSelect ? '' : $value, |
| 766 | + 'text', |
767 | 767 | $tbAttribs ); |
768 | 768 | |
769 | 769 | return "$select<br/>\n$textbox"; |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -472,6 +472,8 @@ |
473 | 473 | * (bug 19531) addPortletLink() now wraps inserted labels in a <span> element to be |
474 | 474 | compatible with the CSS for the Vector skin |
475 | 475 | * (bug 20578) Wrong localized image metadata - duplicated string? |
| 476 | +* (bug 20556) Stub threshold's "other" <input> in Special:Preferences now has a |
| 477 | + correct type="text" parameter |
476 | 478 | |
477 | 479 | == API changes in 1.16 == |
478 | 480 | |