_init()
button()
checkbox()
close()
csrf()
fieldset_close()
fieldset_open()
file()
forge()
hidden()
input()
instance()
label()
open()
password()
prep_value()
radio()
reset()
select()
submit()
textarea()
attr_to_string()
$instance
Form Class
Helper for creating forms with support for creating dynamic form objects.
package | Fuel |
---|---|
category | Core |
_init() : void
checkbox(string | array $field, string $value, mixed $checked, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
mixed
either attributes (array) or bool/string to set checked status
array
string
close() : string
string
csrf() : string
string
fieldset_close() : string
string
fieldset_open(array $attributes, string $legend) : string
array
array with tag attribute settings
string
string for the fieldset legend
string
file(string | array $field, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
array
string
forge($fieldset, array $config)
input(string | array $field, string $value, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
array
string
label(string | array $label, string $id, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
array
string
open(string | array $attributes, array $hidden) : string
string
array
action string or array with more tag attribute settings
array
string
password(string | array $field, string $value, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
array
string
prep_value(string $value) : string
Prepares the value for display in the form
string
string
radio(string | array $field, string $value, mixed $checked, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
mixed
either attributes (array) or bool/string to set checked status
array
string
reset(string | array $field, string $value, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
array
string
select(string | array $field, string $values, array $options, array $attributes) : string
Generates a html select element based on the given parameters
string
array
either fieldname or full attributes array (when array other params are ignored)
string
selected value(s)
array
array of options and option groups
array
string
submit(string | array $field, string $value, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
array
string
textarea(string | array $field, string $value, array $attributes) : string
string
array
either fieldname or full attributes array (when array other params are ignored)
string
array
string
attr_to_string(array $attr) : string
Wraps the global attributes function and does some form specific work
array
string
$instance