Created
May 28, 2009 14:53
-
-
Save lestrrat/119357 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use strict; | |
use HTML::FormHandler; | |
my $form = HTML::FormHandler->new( | |
field_list => { | |
fields => [ | |
foo => { type => 'Text', required => 1 } | |
] | |
} | |
); | |
if (! $form->process( params => { bar => 1 } )) { | |
foreach my $field ($form->error_fields) { | |
foreach my $error ($field->errors) { | |
warn $error; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment