use LWP::UserAgent; use HTTP::Request::Common; my $formurl = "http://www.amihotornot.com/board.pl"; my $id = 20010131; my $username = "MeowChow"; my $password = "catfood"; my $subject = "Fancy Feast is neither fancy nor a feast."; my $post = "Discuss amongst yourselves..."; # construct an anonymous array for the Http::Request::Common::POST met +hod my $formvars = [ id => $id, username => $username, password => $password. subject => $subject, comments => $post, submit => "Submit", ]; $ua = new LWP::UserAgent; $ua->request(POST $formurl, $formvars);
MeowChow print $/='"',(`$^X\144oc $^X\146aq1`)[-2]
In reply to Re: LWP posting a form
by MeowChow
in thread LWP posting a form
by Kickstart
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |