Index: trunk/extensions/SemanticForms/includes/SF_FormField.php |
— | — | @@ -225,9 +225,9 @@ |
226 | 226 | } |
227 | 227 | $text .= $this->inputTypeDropdownHTML( $field_form_text, $default_input_type, $possible_input_types, $template_field->getInputType() ); |
228 | 228 | |
229 | | - if (! is_null( $template_field->getInputType() ) ) { |
| 229 | + if ( !is_null( $template_field->getInputType() ) ) { |
230 | 230 | $cur_input_type = $template_field->getInputType(); |
231 | | - } elseif (! is_null( $default_input_type ) ) { |
| 231 | + } elseif ( !is_null( $default_input_type ) ) { |
232 | 232 | $cur_input_type = $default_input_type; |
233 | 233 | } else { |
234 | 234 | $cur_input_type = $possible_input_types[0]; |
— | — | @@ -272,8 +272,12 @@ |
273 | 273 | } |
274 | 274 | if ( ! $part_of_multiple ) { $text .= "| "; } |
275 | 275 | $text .= "{{{field|" . $this->template_field->getFieldName(); |
| 276 | + // TODO - why is there an input type field in both the form field and the template |
| 277 | + // field? One of them should probably be removed. |
276 | 278 | if ( $this->mIsHidden ) { |
277 | 279 | $text .= "|hidden"; |
| 280 | + } elseif ( !is_null( $this->getInputType() ) ) { |
| 281 | + $text .= "|input type=" . $this->getInputType(); |
278 | 282 | } elseif ( $this->template_field->getInputType() != '' ) { |
279 | 283 | $text .= "|input type=" . $this->template_field->getInputType(); |
280 | 284 | } |