# !d:\\webspace\\seeminternet\\clantm\\clantm.co.uk\\www\\cgi-bin
# File by Graeme Blackwood, llydapdicter@yahoo.co.uk
# Modified from original Net::Ping Module Code
# Designed specifically for the use of Mëtälü§ Grävï§: www.clanmg.net

use CGI qw(:standard);

print header(), start_html("Checking Server Status"), h1("Server Status");
print "<body bgproperties=fixed bgcolor=#000000 background=images/bg.gif text=#d5d1d7 link=#d5d1d7 alink=#88A1B7 vlink=#d5d1d7>\n\n";

@host_array = ("64.177.244.76","26.265.12.15");


use Net::Ping;

    $p = Net::Ping->new("udp");
    foreach $host(@host_array)
    {
        print "<font face=Verdana size=2>$host is: </font>";
           if ($p->ping($host, 2))
           {
              print "<font face=Verdana size=2 color=green><b>Online</b></font>\n";
           }
           else
           {
              print "<font face=Verdana size=2 color=red><b>Offline</b></font>\n";
           }
	print "<br>";
        sleep(1);
    }
    $p->close();
print end_html();
