Perl Home Search CGI

3.3 check for the existance of an URI (LWP)


14.02.2006

3.2 HTTP Header [  up  ] - [ top ] 3.4 Referer / Range

Simple but efficient check for the existance of an URI

use LWP::Simple;

my ($content_type, $document_length, $modified_time) = head $ARGV[0];

print $content_type ? 'OK' : 'FAIL', "\n";

copyright by reto - created with mytexi