HTML::Shakan::Field - base class for field object
This is a base class for filed object.
the 'id' attribute for the html elements.
the 'name' attribute for the html elements.
the 'value' attribute for the html elements.
This is parameter filters in arrayref.
For example, following field removes white space from parameter value in head and end.
TextField( name => 'f', required => 1, filters => [qw'WhiteSpace'] ),
type of widget.
hashref about the miscellaneous attributes.
label for this field.
is this field's value required?
TextField( name => 'id', custom_validation => sub { my ($form, $field) = @_; if (is_reserved_id($form->param($field->name))) { $form->set_error($field->name() => 'reserved'); } } )
You can register custom validation callback.
The callback function takes two arguments.
This is a instance of HTML::Shakan. You can take query parameter value by this object.
The field object itself.
constraints for FormValidator::Lite.
tokuhirom
To install HTML::Shakan, copy and paste the appropriate command in to your terminal.
cpanm
cpanm HTML::Shakan
CPAN shell
perl -MCPAN -e shell install HTML::Shakan
For more information on module installation, please visit the detailed CPAN module installation guide.