in reply to Using LWP's "post" to send n fields into a form?
(Note you might be able to just put widget => \@values in the fields hash, too, but i didn't test it and doesn't explicitly say one way or the other in the docs)use WWW::Mechanize; my $mech = WWW::Mechanize->new; $mech->get($url_of_form); # NOT necessarily the target of the + post # -- this is page w/the actual fo +rm elements $mech->select('widget', \@values); # assumes you get the data from the + CSV into @values # see [fizbin]'s replay above for c +omments on %widget $mech->submit_form( form_name => 'name_of_form', # or use the form_number param # form_number => 3, fields => { # simply set the other form values +here: username => $username, created => '1126175051', } );
|
|---|