HTML-FormFu
view release on metacpan or search on metacpan
- SingleValue
DESCRIPTION
HTML::FormFu is a HTML form framework which aims to be as easy as
possible to use for basic web forms, but with the power and flexibility
to do anything else you might want to do (as long as it involves
forms).
You can configure almost any part of formfu's behaviour and output. By
default formfu renders "XHTML 1.0 Strict" compliant markup, with as
little extra markup as possible, but with sufficient CSS class names to
allow for a wide-range of output styles to be generated by changing
only the CSS.
All methods listed below (except "new") can either be called as a
normal method on your $form object, or as an option in your config
file. Examples will mainly be shown in YAML config syntax.
This documentation follows the convention that method arguments
surrounded by square brackets [] are optional, and all other arguments
PLUGIN SYSTEM
HTML::FormFu provides a plugin-system that allows plugins to be easily
added to a form or element, to change the default behaviour or output.
See HTML::FormFu::Plugin for details.
ADVANCED CUSTOMISATION
By default, formfu renders "XHTML 1.0 Strict" compliant markup, with as
little extra markup as possible. Many hooks are provided to add
programatically-generated CSS class names, to allow for a wide-range of
output styles to be generated by changing only the CSS.
Basic customisation of the markup is possible via the layout and
multi_layout methods. This allows you to reorder the position of
various parts of each field - such as the label, comment, error
messages and the input tag - as well as inserting any other arbitrary
tags you may wish.
examples/unicode/root/view.tt view on Meta::CPAN
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<title>Unicode Demo
</title>
<style type="text/css" media="all">
@import url("[% c.uri_for('/vertically-aligned.css') %]");
</style>
</head>
<body>
examples/vertically-aligned-css/vertically-aligned.html view on Meta::CPAN
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Vertically Aligned</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style type="text/css" media="all">
@import "vertically-aligned.css";
</style>
<!--[if IE]>
<style type="text/css" media="all">
examples/vertically-aligned-css/vertically-aligned.tt view on Meta::CPAN
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Vertically Aligned</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style type="text/css" media="all">
@import "vertically-aligned.css";
</style>
<!--[if IE]>
<style type="text/css" media="all">
lib/HTML/FormFu.pm view on Meta::CPAN
constraints:
- SingleValue
=head1 DESCRIPTION
L<HTML::FormFu> is a HTML form framework which aims to be as easy as
possible to use for basic web forms, but with the power and flexibility to
do anything else you might want to do (as long as it involves forms).
You can configure almost any part of formfu's behaviour and output. By
default formfu renders "XHTML 1.0 Strict" compliant markup, with as little
extra markup as possible, but with sufficient CSS class names to allow for a
wide-range of output styles to be generated by changing only the CSS.
All methods listed below (except L</new>) can either be called as a normal
method on your C<$form> object, or as an option in your config file. Examples
will mainly be shown in L<YAML> config syntax.
This documentation follows the convention that method arguments surrounded
by square brackets C<[]> are I<optional>, and all other arguments are
required.
lib/HTML/FormFu.pm view on Meta::CPAN
=head1 PLUGIN SYSTEM
C<HTML::FormFu> provides a plugin-system that allows plugins to be easily
added to a form or element, to change the default behaviour or output.
See L<HTML::FormFu::Plugin> for details.
=head1 ADVANCED CUSTOMISATION
By default, formfu renders "XHTML 1.0 Strict" compliant markup, with as
little extra markup as possible. Many hooks are provided to add
programatically-generated CSS class names, to allow for a wide-range of
output styles to be generated by changing only the CSS.
Basic customisation of the markup is possible via the
L<layout|HTML::FormFu::Role::Element::Field/layout> and
L<multi_layout|HTML::FormFu::Role::Element::Field/multi_layout> methods.
This allows you to reorder the position of various parts of each field -
such as the label, comment, error messages and the input tag - as well
as inserting any other arbitrary tags you may wish.
lib/HTML/FormFu/Role/Element/Input.pm view on Meta::CPAN
=head2 size
=head1 BOOLEAN ATTRIBUTE ACCESSORS
Arguments: [$bool]
Return Value: $self
Return Value: $string
Return Value: undef
Get / set boolean XHTML attributes such as C<required="required">.
If given any true argument, the attribute value will be set equal to the attribute
key name. E.g. C<< $element->required(1) >> will set the attribute C<< required="required" >>.
If given a false argument, the attribute key will be deleted.
When used as a setter, the return value is C<< $self >> to allow chaining.
=head2 autofocus
( run in 1.026 second using v1.01-cache-2.11-cpan-49f99fa48dc )