Hi!
The script has some errors. Here's a fixed version:
use HTTP::Request; use LWP::UserAgent; my $url = "http://somedomain.com/cgi-bin/somescript.cgi?variouscharact +ers"; my $ua = new LWP::UserAgent; my $req = new HTTP::Request(GET => $url); my $res = $ua->request($req); if ($res->is_success) { print $res->content; } else { die "Not possible\n"; }
Among the other things, you should really use GET as request method for an URL like the one you provided. Also, take a look at the numerous exampels in the LWP documentation, they're very useful.
Michele.
In reply to Re: URL post
by arthas
in thread URL post
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |