davemcgi has asked for the wisdom of the Perl Monks concerning the following question:
$UserAgent = new LWP::UserAgent; $UserAgent->timeout(10); $UserAgent->agent("Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; + rv:1.7.5) Gecko/20041107 Firefox/1.0"); $MyRequest = HTTP::Request->new('GET',"$URL"); $MyResponse = $UserAgent->request($MyRequest); if ($MyResponse->is_success) { $FContent = $MyResponse->content; $FCode = $MyResponse->code; $FBase = $MyResponse->base; } else { $FContent = ""; $FCode = $MyResponse->code; $FBase = ""; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: LWP Timouts
by virtualsue (Vicar) on Oct 31, 2005 at 12:07 UTC | |
|
Re: LWP Timouts
by zentara (Cardinal) on Oct 31, 2005 at 12:45 UTC | |
|
Re: LWP Timouts
by pajout (Curate) on Oct 31, 2005 at 11:42 UTC | |
|
Re: LWP Timouts
by Anonymous Monk on Oct 31, 2005 at 22:32 UTC | |
|
Re: LWP Timouts
by davemcgi (Novice) on Nov 01, 2005 at 08:44 UTC |