marauder has asked for the wisdom of the Perl Monks concerning the following question:
use CGI; use HTTP::Request::Common; use LWP; $ua = LWP::UserAgent->new; my $res= $ua->request(POST 'http://server.com/cgi-bin/upload.cgi', [description => 'a description', filetoupload => 'c:/test.dat' ]); if ($res->is_success) {print "success\n";} else {print "failed $!\n";}
I always get "failed invalid argument". Any help much appreciated. by the way sqware brackets are included but don't show in the code above.
2001-12-06 Edit by Corion : Added Code tags
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: http upload simulating browser
by miyagawa (Chaplain) on Dec 07, 2001 at 00:36 UTC | |
|
Re: http upload simulating browser
by IlyaM (Parson) on Dec 07, 2001 at 00:37 UTC | |
|
Re: http upload simulating browser
by Fastolfe (Vicar) on Dec 07, 2001 at 01:03 UTC | |
|
Re: http upload simulating browser
by jlongino (Parson) on Dec 07, 2001 at 01:40 UTC | |
by IlyaM (Parson) on Dec 07, 2001 at 01:54 UTC |