in reply to LWP for URL monitoring - 500 connect timeout errors
And following is the response to ach of the abiove websites: C:\SCRIPTING>urltestv5.pl http://www.eserve.com.sa 400 Bad Request C:\SCRIPTING>urltestv5.pl http://www1.elm.com.sa/Portal/Ar/Topics/Services/ 200 OK Is there any way around this? Or if I can capture the redirection from the script itself and then do HEAD to that? Any ideas? Appreciate your support and assistance# !C:\Perl\bin use strict; use warnings; use LWP::UserAgent; my $url = shift or die "URL expected\n"; my $useragent = LWP::UserAgent->new; $useragent->proxy(['http', 'ftp','https'], 'http://192.168.5.39:8080/' +); $useragent -> timeout( 20 ); my $request = HTTP::Request->new( HEAD => $url ); my $response = $useragent->request($request); print $response->status_line, "\n"; print $response->is_success, "\n"; print $useragent->proxy('http'),"\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: LWP for URL monitoring - 500 connect timeout errors
by Anonymous Monk on Jul 20, 2009 at 13:52 UTC | |
by Anonymous Monk on Jul 21, 2009 at 08:42 UTC | |
by Anonymous Monk on Jul 21, 2009 at 10:15 UTC | |
by Anonymous Monk on Jul 21, 2009 at 10:48 UTC | |
by Anonymous Monk on Jul 21, 2009 at 13:44 UTC | |
| |
by Anonymous Monk on Jul 21, 2009 at 13:22 UTC |