[Html-widget] Setting field values using query parameters

Carl Franks fireartist at gmail.com
Tue Oct 17 10:25:57 CEST 2006


On 17/10/06, Zbigniew Lukasiak <zzbbyy at gmail.com> wrote:
>
> I am sure process() does preserve the values, I am using that.

Yup...

$ perl -MHTML::Widget -le '
my $w = HTML::Widget->new;
my $e = $w->element( Textfield => q{foo} );
$e->value( q{bar} );
my $r = $w->process;
print $r;
' | splithtml
<form id="widget" method="post">
<fieldset class="widget_fieldset">
<input class="textfield" id="widget_foo" name="foo" type="text" value="bar" />
</fieldset>
</form>



More information about the Html-widget mailing list