function fieldPlain()
Return HTML for a 'plain' field, i.e. one which doesn't require a FIELDSET wrapped around it.
The main wrapping DIV will contain additional classes if the field is required, disabled or has an error.
A class is also output for the field method name (if the name contains "Sprout\Helpers\Fb::" this is removed)
If the field has an explicit ID set, that will be added as a class on the wrapper too.
The special attribute "-wrapper-class" can be used to add classes to the wrapper DIV.
Multiple classes can be specified, space separated.
These classes will be prefixed with "field-element--" Usagestring Form::fieldPlain ( callable $method , string $name , array $attrs , array $options ); Example// Adds the class "field-element--small" to the wrapper
echo Form::fieldPlain('Sprout\Helpers\Fb::text', 'first_name', ['-wrapper-class' => 'small'], []); Example// Adds the class "field-element--id-first-name" to the wrapper
echo Form::fieldPlain('Sprout\Helpers\Fb::text', 'first_name', ['id' => 'first-name'], []); Exampleecho Form::fieldPlain('Sprout\Helpers\Fb::text', 'first_name', [], []); Arguments- callable $method
The actual field rendering method - string $name
The field name - this is passed to the rendering method - array $attrs
The field attrs - this is passed to the rendering method - array $options
The field options - this is passed to the rendering method
Return value
|