[html-formfu] Multiple Submits

Carl Franks fireartist at gmail.com
Fri Aug 17 11:30:11 GMT 2007


On 15/08/07, Moritz Onken <onken at houseofdesign.de> wrote:
> There is a little bug. If you do it as I wrote the value of the
> unclicked button will be "" after submission. If you have an error on
> that form the new page will have an empty submit button.
>
>
>         $form->add_valid( $_->name, $_->value )
>           for ( @{ $form->get_elements( { type => 'submit' } ) }

I've fixed this by making submit buttons have retain_default(1).
Now, regardless of which submit button is clicked, they will all still
have their default value when you redisplay the form.

Carl



More information about the HTML-FormFu mailing list