r71483 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r71482‎ | r71483 | r71484 >
Date:13:55, 23 August 2010
Author:yaron
Status:deferred
Tags:
Comment:
New comboboxHTML() function, changes to all autocompletion to use jQuery instead of YUI, change from Floatbox to FancyBox JS library, and new 'autogrow' functionality for textareas, all added by Sanyam Goyal; various changes to inputs to fix bugs in both 'show on select' and mandatory validation; other small HTML improvements
Modified paths:
  • /trunk/extensions/SemanticForms/includes/SF_FormInputs.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticForms/includes/SF_FormInputs.php
@@ -6,15 +6,15 @@
77 * @author Jeffrey Stuckman
88 * @author Matt Williamson
99 * @author Patrick Nagel
 10+ * @author Sanyam Goyal
1011 */
1112
1213 class SFFormInputs {
13 -
1414 /**
15 - * Create a comma-delimited string of values that match the specified
16 - * source name and type, for use by Javascript autocompletion.
 15+ * Creates an array of values that match the specified source name and type,
 16+ * for use by both Javascript autocompletion and comboboxes.
1717 */
18 - static function createAutocompleteValuesString( $source_name, $source_type ) {
 18+ static function createAutocompleteValuesArray( $source_name, $source_type ) {
1919 $names_array = array();
2020 // the query depends on whether this is a property, category, concept
2121 // or namespace
@@ -30,9 +30,19 @@
3131 $source_name = "";
3232 $names_array = SFUtils::getAllPagesForNamespace( $source_name );
3333 }
 34+ return $names_array;
 35+ }
 36+
 37+
 38+ /**
 39+ * Creates a comma-delimited string of values that match the specified
 40+ * source name and type, for use by Javascript autocompletion.
 41+ */
 42+ static function createAutocompleteValuesString( $source_name, $source_type ) {
 43+ $names_array = self::createAutocompleteValuesArray( $source_name, $source_type );
3444 // escape quotes, to avoid Javascript errors
3545 $names_array = array_map( 'addslashes', $names_array );
36 - $autocomplete_string = "[['" . implode( "'], ['", $names_array ) . "']]";
 46+ $autocomplete_string = "['" . implode( "', '", $names_array ) . "']";
3747 // replace any newlines in the string, just to avoid breaking the Javascript
3848 $autocomplete_string = str_replace( "\n", ' ', $autocomplete_string );
3949 $autocomplete_string = str_replace( "\r", ' ', $autocomplete_string );
@@ -40,8 +50,11 @@
4151 }
4252
4353 static function uploadLinkHTML( $input_id, $delimiter = null, $default_filename = null ) {
 54+ global $wgOut, $sfgScriptPath, $sfgFancyBoxIncluded;
 55+
4456 $upload_window_page = SpecialPage::getPage( 'UploadWindow' );
4557 $query_string = "sfInputID=$input_id";
 58+ $fancybox_id = "fancybox_$input_id";
4659 if ( $delimiter != null )
4760 $query_string .= "&sfDelimiter=$delimiter";
4861 if ( $default_filename != null )
@@ -53,7 +66,31 @@
5467 $style = "width:650 height:500";
5568 else
5669 $style = '';
57 - $text = " <a href=\"$upload_window_url\" title=\"$upload_label\" rel=\"iframe\" rev=\"$style\">$upload_label</a>";
 70+
 71+ if ( !$sfgFancyBoxIncluded ) {
 72+ $sfgFancyBoxIncluded = true;
 73+ $wgOut->addScriptFile( "$sfgScriptPath/libs/jquery.fancybox-1.3.1.js" );
 74+ }
 75+
 76+ $fancybox_js =<<<END
 77+<script type="text/javascript">
 78+jQuery(document).ready(function() {
 79+ jQuery("#$fancybox_id").fancybox({
 80+ 'width' : '75%',
 81+ 'height' : '75%',
 82+ 'autoScale' : false,
 83+ 'transitionIn' : 'none',
 84+ 'transitionOut' : 'none',
 85+ 'type' : 'iframe',
 86+ 'overlayColor' : '#222',
 87+ 'overlayOpacity' : '0.8',
 88+ });
 89+});
 90+</script>
 91+END;
 92+ $wgOut->addScript($fancybox_js);
 93+
 94+ $text = " <a id = \"$fancybox_id\" href=\"$upload_window_url\" title=\"$upload_label\" rev=\"$style\">$upload_label</a>";
5895 return $text;
5996 }
6097
@@ -273,9 +310,7 @@
274311 if ( array_key_exists( 'class', $other_args ) )
275312 $span_class .= " " . $other_args['class'];
276313 $input_id = "input_$sfgFieldNum";
277 - $info_id = "info_$sfgFieldNum";
278314 $hidden_input_name = $input_name . "[is_list]";
279 - $disabled_text = ( $is_disabled ) ? "disabled" : "";
280315 // get list delimiter - default is comma
281316 if ( array_key_exists( 'delimiter', $other_args ) ) {
282317 $delimiter = $other_args['delimiter'];
@@ -289,32 +324,50 @@
290325 $text = "";
291326 $return_js_text = "";
292327 $enum_input_ids = array();
293 - // if it's mandatory, add a span around all the checkboxes, since
294 - // some browsers don't support formatting of checkboxes
295 - if ( $is_mandatory )
296 - $text .= ' <span class="mandatoryFieldsSpan">' . "\n";
297328 foreach ( $possible_values as $key => $possible_value ) {
298329 // create array $enum_input_ids to associate values with their input IDs,
299330 // for use in creating the 'show on select' Javascript later
300331 $enum_input_ids[$possible_value] = $input_id;
301332 $cur_input_name = $input_name . "[" . $key . "]";
302 - $checked_text = ( in_array( $possible_value, $cur_values ) ) ? 'checked="checked"' : "";
303333
304334 if ( array_key_exists( 'value_labels', $other_args ) && is_array( $other_args['value_labels'] ) && array_key_exists( $possible_value, $other_args['value_labels'] ) )
305335 $label = htmlspecialchars( $other_args['value_labels'][$possible_value] );
306336 else
307337 $label = $possible_value;
308 - $text .= <<<END
309 - <span class="$span_class"><input type="checkbox" id="$input_id" tabindex="$sfgTabIndex" name="$cur_input_name" value="$possible_value" class="$checkbox_class" $checked_text $disabled_text/> $label</span>
310338
311 -END;
 339+ $checkbox_attrs = array(
 340+ 'type' => 'checkbox',
 341+ 'id' => $input_id,
 342+ 'tabindex' => $sfgTabIndex,
 343+ 'name' => $cur_input_name,
 344+ 'value' => $possible_value,
 345+ 'class' => $checkbox_class,
 346+ );
 347+ if ( in_array( $possible_value, $cur_values ) ) {
 348+ $checkbox_attrs['checked'] = 'checked';
 349+ }
 350+ if ( $is_disabled ) {
 351+ $checkbox_attrs['disabled'] = 'disabled';
 352+ }
 353+ $checkbox_input = Xml::element( 'input', $checkbox_attrs );
 354+ $text .= ' ' . Xml::tags( 'span',
 355+ array( 'class' => $span_class ),
 356+ $checkbox_input . ' ' . $label
 357+ ) . "\n";
312358 $sfgTabIndex++;
313359 $sfgFieldNum++;
314360 $input_id = "input_$sfgFieldNum";
315361 }
316 - // close span
317 - if ( $is_mandatory )
318 - $text .= " </span>";
 362+ // if it's mandatory, add a span around all the checkboxes, since
 363+ // some browsers don't support formatting of checkboxes
 364+ if ( $is_mandatory ) {
 365+ $text = ' ' . Xml::tags( 'span',
 366+ array(
 367+ 'id' => $input_id,
 368+ 'class' => 'mandatoryFieldsSpan',
 369+ ), $text ) . "\n";
 370+ }
 371+ $info_id = "info_$sfgFieldNum";
319372 $text .= <<<END
320373 <span id="$info_id" class="errorMessage"></span>
321374 <input type="hidden" name="$hidden_input_name" value="1" />
@@ -358,6 +411,81 @@
359412 return array( $text, $return_js_text );
360413 }
361414
 415+ static function comboboxHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args ) {
 416+ if ( array_key_exists( 'no autocomplete', $other_args ) &&
 417+ $other_args['no autocomplete'] == true ) {
 418+ unset( $other_args['autocompletion source'] );
 419+ return SFFormInputs::textEntryHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args );
 420+ }
 421+ // if a set of values was specified, print a dropdown instead
 422+ if ( array_key_exists( 'possible_values', $other_args ) && $other_args['possible_values'] != null )
 423+ return SFFormInputs::dropdownHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args );
 424+
 425+ global $sfgTabIndex, $sfgFieldNum,$wgOut, $sfgScriptPath,$wgJsMimeType, $smwgScriptPath,$smwgJqUIAutoIncluded;
 426+
 427+ $autocomplete_field_type = "";
 428+ $autocompletion_source = "";
 429+
 430+ $className = ( $is_mandatory ) ? "autocompleteInput mandatoryField" : "autocompleteInput createboxInput";
 431+ if ( array_key_exists( 'class', $other_args ) )
 432+ $className .= " " . $other_args['class'];
 433+ $disabled_text = ( $is_disabled ) ? "disabled" : "";
 434+ if ( array_key_exists( 'autocomplete field type', $other_args ) ) {
 435+ $autocomplete_field_type = $other_args['autocomplete field type'];
 436+ $autocompletion_source = $other_args['autocompletion source'];
 437+ if ( $autocomplete_field_type != 'external_url' ) {
 438+ global $wgContLang;
 439+ $autocompletion_source = $wgContLang->ucfirst( $autocompletion_source );
 440+ }
 441+ }
 442+ if ( array_key_exists( 'size', $other_args ) )
 443+ $size = $other_args['size'];
 444+ else
 445+ $size = "35";
 446+
 447+ $input_id = "input_" . $sfgFieldNum;
 448+ $info_id = "info_" . $sfgFieldNum;
 449+ $div_name = "div_" . $sfgFieldNum;
 450+
 451+ $options_str_key = $autocompletion_source;
 452+ $javascript_text = "autocompletemappings[$sfgFieldNum] = '$options_str_key';\n";
 453+
 454+ $values = array();
 455+ $values = self::createAutocompleteValuesArray($autocompletion_source, $autocomplete_field_type );
 456+
 457+
 458+ /*adding code for displaying dropdown of autocomplete values*/
 459+
 460+ $text =<<<END
 461+<div class="ui-widget">
 462+ <select id="input_$sfgFieldNum" name="$input_name">
 463+ <option value="$cur_value"></option>
 464+
 465+END;
 466+ foreach ($values as $value) {
 467+ $text .= " <option value=\"$value\">$value</option>\n";
 468+ }
 469+ $text .= <<<END
 470+ </select>
 471+ <span id="$info_id" class="errorMessage"></span>
 472+</div>
 473+<script type="text/javascript" >
 474+jQuery(function() {jQuery("#input_$sfgFieldNum").combobox();});
 475+</script>
 476+END;
 477+ // there's no direct correspondence between the 'size=' attribute for
 478+ // text inputs and the number of pixels, but multiplying by 6 seems to
 479+ // be about right for the major browsers
 480+ $pixel_width = $size * 6;
 481+ $combobox_css =<<<END
 482+<style type="text/css">
 483+input#input_$sfgFieldNum { width: {$pixel_width}px; }
 484+</style>
 485+END;
 486+ $wgOut->addScript($combobox_css);
 487+ return array( $text, $javascript_text );
 488+ }
 489+
362490 static function textInputWithAutocompleteHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args ) {
363491 // if 'no autocomplete' was specified, print a regular text entry instead
364492 if ( array_key_exists( 'no autocomplete', $other_args ) &&
@@ -369,7 +497,7 @@
370498 if ( array_key_exists( 'possible_values', $other_args ) && $other_args['possible_values'] != null )
371499 return SFFormInputs::dropdownHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args );
372500
373 - global $sfgTabIndex, $sfgFieldNum;
 501+ global $sfgTabIndex, $sfgFieldNum, $wgOut, $sfgScriptPath,$wgJsMimeType, $smwgScriptPath,$smwgJqUIAutoIncluded;
374502
375503 $className = ( $is_mandatory ) ? "autocompleteInput mandatoryField" : "autocompleteInput createboxInput";
376504 if ( array_key_exists( 'class', $other_args ) )
@@ -387,6 +515,7 @@
388516 $info_id = "info_" . $sfgFieldNum;
389517 $div_name = "div_" . $sfgFieldNum;
390518 if ( array_key_exists( 'input_type', $other_args ) && $other_args['input_type'] == "textarea" ) {
 519+
391520 $rows = $other_args['rows'];
392521 $cols = $other_args['cols'];
393522 if ( array_key_exists( 'maxlength', $other_args ) ) {
@@ -398,10 +527,23 @@
399528 } else {
400529 $js_call = "";
401530 }
402 - $text = <<<END
403 - <textarea tabindex="$sfgTabIndex" id="$input_id" name="$input_name" rows="$rows" cols="$cols" class="$className" $disabled_text $js_call></textarea>
 531+ $text = "";
 532+ if ( array_key_exists( 'autogrow', $other_args ) ) {
 533+ $text .= <<<END
 534+<script type="text/javascript">
 535+ jQuery.noConflict();
 536+ jQuery(document).ready(function() {
 537+ jQuery("#$input_id").autoGrow();
 538+ });
 539+</script>
404540
405541 END;
 542+ $className .= ' autoGrow';
 543+ }
 544+
 545+ $text .= <<<END
 546+ <textarea tabindex="$sfgTabIndex" id="$input_id" name="$input_name" rows="$rows" cols="$cols" class="$className" $disabled_text $js_call></textarea>
 547+END;
406548 } else {
407549 if ( array_key_exists( 'size', $other_args ) )
408550 $size = $other_args['size'];
@@ -410,6 +552,7 @@
411553
412554 $text = <<<END
413555 <input tabindex="$sfgTabIndex" id="$input_id" name="$input_name" type="text" value="" size="$size" class="$className"
 556+
414557 END;
415558 if ( $is_disabled )
416559 $text .= " disabled";
@@ -442,7 +585,8 @@
443586 <script type="text/javascript">/* <![CDATA[ */
444587
445588 END;
446 - $options_str_key = str_replace( "'", "\'", $autocompletion_source );
 589+
 590+ $options_str_key = $autocompletion_source;
447591 if ( $is_list ) {
448592 $options_str_key .= ",list";
449593 if ( $delimiter != "," ) {
@@ -464,12 +608,13 @@
465609 $cur_value = str_replace( "\r", '\r', $cur_value );
466610 $text .= "document.getElementById('$input_id').value = \"$cur_value\"\n";
467611 }
468 - $text .= "/* ]]> */</script>\n";
 612+ $text .= '/* ]]> */</script>';
469613 return array( $text, $javascript_text );
470614 }
471615
472616 static function textAreaHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args ) {
473617 // set size values
 618+
474619 if ( ! array_key_exists( 'rows', $other_args ) )
475620 $other_args['rows'] = 5;
476621 if ( ! array_key_exists( 'cols', $other_args ) )
@@ -481,7 +626,7 @@
482627 return SFFormInputs::textInputWithAutocompleteHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args );
483628 }
484629
485 - global $sfgTabIndex, $sfgFieldNum;
 630+ global $sfgTabIndex, $sfgFieldNum, $smwgScriptPath, $sfgScriptPath,$wgOut;
486631
487632 $className = ( $is_mandatory ) ? "mandatoryField" : "createboxInput";
488633 if ( array_key_exists( 'class', $other_args ) )
@@ -504,7 +649,23 @@
505650 }
506651
507652 $cur_value = htmlspecialchars( $cur_value );
508 - $text = <<<END
 653+ $text = "";
 654+ if ( array_key_exists( 'autogrow', $other_args ) ) {
 655+ $wgOut->addScriptFile( "$sfgScriptPath/libs/SF_autogrow.js" );
 656+ $text .= <<<END
 657+<script type="text/javascript">
 658+ jQuery.noConflict();
 659+ jQuery(document).ready(function(){
 660+ jQuery("#$input_id").autoGrow();
 661+ });
 662+</script>
 663+
 664+END;
 665+ $className .= ' autoGrow';
 666+ }
 667+
 668+ $text .= <<<END
 669+
509670 <textarea tabindex="$sfgTabIndex" id="$input_id" name="$input_name" rows="$rows" cols="$cols" class="$className" $disabled_text $js_call>$cur_value</textarea>
510671 <span id="$info_id" class="errorMessage"></span>
511672
@@ -652,61 +813,132 @@
653814 static function radioButtonHTML( $cur_value, $input_name, $is_mandatory, $is_disabled, $other_args ) {
654815 global $sfgTabIndex, $sfgFieldNum;
655816
656 - $input_id = "input_$sfgFieldNum";
657 - $info_id = "info_$sfgFieldNum";
658 - $disabled_text = ( $is_disabled ) ? "disabled" : "";
 817+ $span_class = "checkboxSpan";
 818+ if ( array_key_exists( 'class', $other_args ) )
 819+ $span_class .= " " . $other_args['class'];
 820+
659821 $check_set = false;
660 - $javascript_text = '';
661 - $return_js_text = '';
662 - if ( array_key_exists( 'show on select', $other_args ) ) {
663 - $javascript_text = 'onClick="';
664 - foreach ( $other_args['show on select'] as $div_id => $options ) {
665 - $options_str = implode( "', '", $options );
666 - $this_js_text = "showIfSelected('$input_id', ['$options_str'], '$div_id'); ";
667 - $javascript_text .= $this_js_text;
668 - $return_js_text .= $this_js_text . "\n";
669 - }
670 - $javascript_text .= '"';
671 - }
672822 $text = "";
673823 // if it's mandatory, add a span around all the radiobuttons, since
674824 // some browsers don't support formatting of radiobuttons
675825 if ( $is_mandatory )
676826 $text .= ' <span class="mandatoryFieldsSpan">' . "\n";
677827
678 - // start with an initial "None" value, unless this is a mandatory field
679 - // and there's a current value in place (either through a default value
680 - // or because we're editing an existing page)
 828+ if ( ( $possible_values = $other_args['possible_values'] ) == null )
 829+ $possible_values = array();
 830+
 831+ // Add a "None" value, unless this is a mandatory field and there's a
 832+ // current value in place (either through a default value or because
 833+ // we're editing an existing page).
 834+ // We place it at the end of the array, instead of the beginning (even
 835+ // though it gets displayed at the beginning) so that the "None" value's
 836+ // ID will match that of the "error message" span, which is created at
 837+ // the end of the process - the validation Javascript requires that the
 838+ // two be matching
681839 if ( ! $is_mandatory || $cur_value == '' ) {
682 - $text .= ' <input type="radio" id="' . $input_id . '" tabindex="' . $sfgTabIndex . '" name="' . $input_name . '" value=""';
683 - if ( ! $cur_value ) {
684 - $text .= ' checked="checked"';
685 - $check_set = true;
686 - }
687 - $text .= " $disabled_text $javascript_text/> " . wfMsg( 'sf_formedit_none' ) . "\n";
 840+ $possible_values[] = '';
688841 }
689842
690 - if ( ( $possible_values = $other_args['possible_values'] ) == null )
691 - $possible_values = array();
 843+ // Set $cur_value to be one of the allowed options, if it isn't already -
 844+ // that makes it easier to automatically have one of the radiobuttons
 845+ // be checked at the beginning.
 846+ if ( ! in_array( $cur_value, $possible_values ) ) {
 847+ if ( in_array( '', $possible_values ) )
 848+ $cur_value = '';
 849+ else
 850+ $cur_value = $possible_values[0];
 851+ }
 852+
 853+ $enum_input_ids = array();
 854+ $radiobuttons_text = '';
 855+ $none_radiobutton_text = '';
692856 foreach ( $possible_values as $i => $possible_value ) {
693 - $text .= ' <input type="radio" tabindex="' . $sfgTabIndex . '" name="' . $input_name . '" value="' . $possible_value . '"';
694 - if ( $cur_value == $possible_value || ( ! $cur_value && ! $check_set ) ) {
695 - $text .= ' checked="checked"';
696 - $check_set = true;
 857+ $sfgTabIndex++;
 858+ $sfgFieldNum++;
 859+ $input_id = "input_$sfgFieldNum";
 860+
 861+ // create array $enum_input_ids to associate values with their input IDs,
 862+ // for use in creating the 'show on select' Javascript later
 863+ $enum_input_ids[$possible_value] = $input_id;
 864+
 865+ $radiobutton_attrs = array(
 866+ 'type' => 'radio',
 867+ 'id' => $input_id,
 868+ 'tabindex' => $sfgTabIndex,
 869+ 'name' => $input_name,
 870+ 'value' => $possible_value,
 871+ );
 872+ if ( $cur_value == $possible_value ) {
 873+ $radiobutton_attrs['checked'] = 'checked';
697874 }
698 - if ( array_key_exists( 'value_labels', $other_args ) && is_array( $other_args['value_labels'] ) && array_key_exists( $possible_value, $other_args['value_labels'] ) )
 875+ if ( $is_disabled ) {
 876+ $radiobutton_attrs['disabled'] = 'disabled';
 877+ }
 878+ if ( $possible_value == '' ) // blank/"None" value
 879+ $label = wfMsg( 'sf_formedit_none' );
 880+ elseif ( array_key_exists( 'value_labels', $other_args ) && is_array( $other_args['value_labels'] ) && array_key_exists( $possible_value, $other_args['value_labels'] ) )
699881 $label = htmlspecialchars( $other_args['value_labels'][$possible_value] );
700882 else
701883 $label = $possible_value;
702 - $text .= " $disabled_text $javascript_text/> $label\n";
 884+
 885+ $radiobutton_text = ' ' .
 886+ Xml::element ( 'input', $radiobutton_attrs ) . " $label\n";
 887+
 888+ // There's special handling for the "None" radiobutton, if it exists,
 889+ // because it's created last but displayed first - see above.
 890+ if ( $possible_value == '' ) {
 891+ $none_radiobutton_text = $radiobutton_text;
 892+ } else {
 893+ $radiobuttons_text .= $radiobutton_text;
 894+ }
703895 }
 896+ $text = $none_radiobutton_text . $radiobuttons_text;
 897+
704898 // close span
705899 if ( $is_mandatory )
706900 $text .= " </span>";
 901+ $info_id = "info_$sfgFieldNum";
707902 $text .= <<<END
708903 <span id="$info_id" class="errorMessage"></span>
709904
710905 END;
 906+
 907+ // Finally, we do the 'show on select' handling.
 908+ $return_js_text = '';
 909+ if ( array_key_exists( 'show on select', $other_args ) ) {
 910+ foreach ( $other_args['show on select'] as $div_id => $options ) {
 911+ $cur_input_ids = array();
 912+ foreach ( $options as $option ) {
 913+ if ( array_key_exists( $option, $enum_input_ids ) ) {
 914+ $cur_input_ids[] = $enum_input_ids[$option];
 915+ }
 916+ }
 917+ $options_str = "['" . implode( "', '", $cur_input_ids ) . "']";
 918+ $cur_js_text = "showIfChecked($options_str, '$div_id'); ";
 919+ $return_js_text .= $cur_js_text . "\n";
 920+ foreach ( $possible_values as $key => $possible_value ) {
 921+ // We need to add each click handler to each radiobutton,
 922+ // because there doesn't seem to be any way for a radiobutton
 923+ // to know that it was unchecked - rather, the newly-checked
 924+ // radiobutton has to handle the change.
 925+ foreach ( $enum_input_ids as $cur_input_id ) {
 926+ // we use addClickHandler(), instead of adding the Javascript via
 927+ // onClick="", because MediaWiki's wikibits.js does its own handling
 928+ // of checkboxes, which impacts their behavior in IE
 929+ if ( in_array( $possible_value, $options ) ) {
 930+ $return_js_text .= <<<END
 931+addClickHandler(
 932+ document.getElementById('$cur_input_id'),
 933+ function() { $cur_js_text }
 934+);
 935+
 936+END;
 937+ }
 938+ }
 939+ }
 940+ }
 941+ }
 942+
711943 return array( $text, $return_js_text );
712944 }
713945
@@ -800,7 +1032,6 @@
8011033 $text .= ' <input type="radio" id="' . $input_id . '" tabindex="' . $sfgTabIndex . '" name="' . $input_name . '" value=""';
8021034 if ( ! $cur_value ) {
8031035 $text .= ' checked="checked"';
804 - $check_set = true;
8051036 }
8061037 $disabled_text = ( $is_disabled ) ? "disabled" : "";
8071038 $text .= " $disabled_text/> <em>" . wfMsg( 'sf_formedit_none' ) . "</em>\n";

Status & tagging log