#!/usr/bin/perl use CGI; use LWP::UserAgent; my $q = new CGI;
my $query = $q->param('query') || 'LWP'; use LWP::UserAgent; my $ua = LWP::UserAgent->new; my $response = $ua->get("http://search.cpan.org/search?query=$query"); if ($response->is_success) { my $server_response = $response->content; print $server_response; } ----- Original Message ----- From: "Tobias Fink" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, November 07, 2003 4:12 AM Subject: HTTP::Request > Hi, > > why doesn't > > my $ua = LWP::UserAgent->new; > my $res = $ua->request(GET 'http://www.google.de/search', q => 'asdasd'); > if ($res->is_success) { > my $server_response = $res->content; > print $server_response; > } > > print the html-source of http://www.google.de/search?q=asdasd ? > > > Regards, > > Tobias > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]