or download this
use Data::Validate::IP qw(is_ip is_public_ip is_loopback_ip);
@IPs='';
...
};
};
print "Content-type: text/html\nCache-Control: max-age=0,no-cache,no-s
+tore,post-check=0,pre-check=0\n\n<html><head><title>Current IP Check<
+/title></head><body>Current IP Address: $ip</body></html>";