--------------------------
my ($ua, $req, $res);
$ua = new LWP::UserAgent;
$ua->agent("$ENV{'HTTP_USER_AGENT'}");
my $cookie_jar = HTTP::Cookies->new;
$req = new HTTP::Request GET => "http://beersite.netfirms.com/index.html";
$req->header('Accept' => 'text/html');
$res = $ua->request($req);
$cookie_jar->extract_cookies($res);
print "Content-type: text/html\n\n";
print "HTTP GET Request sent to http://beersite.netfirms.com/index.html<br>\n";
print "User Agent : ".$ua->agent."<br>\nHTTP proxy : ".$ua->proxy('http')."<br>\n";
print "Results:<br>\n";
print "Code : ".$res->code."<br>\nStatus line : ".$res->status_line."<br>\nLocation : ".$res->header('location')."<br>\n";
------------------------------
if you want to see it running, go to http://beersite.netfirms.com/cgi-bin/temp.pl
Thanks,
Shahar.
[EMAIL PROTECTED] wrote:
well, i've been trying to grap a page from my own site, and it gives me
the same error.
Hi Shahar, This sends like a code problem then. Can you post a relevant snippet of your code?joel
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]