Catalyst::Plugin::HTML::Widget(3pm)

Catalyst::Plugin::HTML::Widget3pm

Html widget and validation framework

Usage

    use Catalyst qw/HTML::Widget;
    $c->widget('foo')->method('get')->action('/foo/action');
    $c->widget('foo')->element( 'Textfield', 'age' )->label('Age')->size(3);
    $c->widget('foo')->element( 'Textfield', 'name' )->label('Name')->size(60);
    $c->widget('foo')->element( 'Submit', 'ok' )->value('OK');
    $c->widget('foo')->constraint( 'Integer', 'age' )->message('No integer.');
    $c->widget('foo')->constraint( 'All', 'age', 'name' )
        ->message('Missing value.');
    $c->widget( HTML::Widget->new('foo') );
    $c->widget('foo')->indicator('some_field');
    my $result = $c->widget('foo')->process;
    my $result = $c->widget('foo')->process($query);
    my $result = $c->widget_result('foo');      #  with query params

Overview

HTML Widget And Validation Framework.

Methods

$c->widget( $name, $widget )

Returns a HTML::Widget. If no object exists, it will be created on the fly. The widget name defaults to "_widget".

$c->widget_result($name)

Returns a HTML::Widget::Result object, processed with query and upload parameters.

Releases

2 releases since Debian 4.0 (Etch); the text changed 1 time.

  1. 4.0
  2. 5.0

Author

Sebastian Riedel, "[email protected]"

License

This library is free software, you can redistribute it and/or modify it under the same terms as Perl itself.

From libcatalyst-modules-perl 31 in Debian 5.0 (Lenny). Parsed by carta from the page's man source.