public
Created

Fuel form : build fields

  • Download Gist
form.php
PHP
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
<?php
 
class Form extends \Fuel\Core\Form {
public function field_template_public($build_field, \Fuel\Core\Fieldset_Field $field, $required) {
return parent::field_template($build_field, $field, $required);
}
public function build_field($field) {
if (substr(strtolower(\Inflector::denamespace(get_class($field))), 0, 6) == 'widget') {
// Widgets build themselves
return $field->build();
}
return parent::build_field($field);
}
}

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.