I use a form to let the user input a URL, when the user input a url and
click the "Test URL" button, a window popup and tell the user whether the
URL is valid.
I write a OnClick event handle for the Test Button to open the new window
and transfer a param url to the TestURL.pl file.
My program
At 05:06 PM 11/14/00 +0800, spring wrote:
My program works fine when test on most URL, but with some, I always get a
error status such as 500, 403,etc, even when the url can be visited
correctlly in browser.
[snip]
my $req = HTTP::Request-new(HEAD = $url);
Many servers are busted and will
Bill Moseley [EMAIL PROTECTED] writes:
Many servers are busted and will return a 500 error on a HEAD request. I
remember Cold Fusion being one.
Maybe there's a better way, but this is what I do to validate a URL:
$req = HTTP::Request-new( GET = $url );
$ua-timeout(
At 03:36 PM 11/14/00 -0800, Gisle Aas wrote:
Maybe there's a better way, but this is what I do to validate a URL:
$req = HTTP::Request-new( GET = $url );
$ua-timeout( $LWP_GET_WAIT || 30 );
$res = $ua-simple_request( $req, sub { die }, 100 );
The same effect can also be
Bill Moseley [EMAIL PROTECTED] writes:
At 03:36 PM 11/14/00 -0800, Gisle Aas wrote:
Maybe there's a better way, but this is what I do to validate a URL:
$req = HTTP::Request-new( GET = $url );
$ua-timeout( $LWP_GET_WAIT || 30 );
$res = $ua-simple_request( $req, sub { die