Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Above code constantly gives me failure. If I try the 'html form' provided and submit via browser, it works fine.#!/perl/bin/perl use HTTP::Request::Common qw(POST); use LWP::UserAgent; my $ua = new LWP::UserAgent; my $req = POST 'http://someprivatesite.com/getfile.cgi', [ "./some.xml",'xml_file','Content-type' => 'multipart/form-data' +]; my $res = $ua->request($req); print $res->as_string;
Thanks for your help
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Uploading a file via LWP
by pizza_milkshake (Monk) on May 01, 2004 at 00:00 UTC | |
by Anonymous Monk on May 03, 2004 at 14:23 UTC |