// fetch the definition of this form $formdata = \Config::get('forms'); // add a form header $formdata['form_template'] = str_replace('{legend}', __('global.information'), $formdata['form_template']); $formdata['form_template'] = str_replace('{info}', $info, $formdata['form_template']); $formdata['form_template'] = str_replace('{header}', $title, $formdata['form_template']); // add buttons $formdata['form_template'] = str_replace('{buttons}', Form::submit('formbutton[save]', __('global.save'), array('id' => 'form_formbutton[save]', 'class' => 'formbutton positive')). Form::submit('formbutton[refresh]', __('global.refresh'), array('id' => 'form_formbutton[refresh]', 'class' => 'formbutton', 'formnovalidate')). Form::submit('formbutton[cancel]', __('global.cancel'), array('id' => 'form_formbutton[cancel]', 'class' => 'formbutton negative', 'formnovalidate')), $formdata['form_template'] ); // create the fieldset $fieldset = Fieldset::forge('users')->set_config($formdata)->set_config(array('form_attributes' => array('onsubmit' => 'fuel_set_csrf_token(this)')))->add_model($model)->repopulate();
It looks like you're new here. If you want to get involved, click one of these buttons!