Server Monitor
public php v1 · immutable<?php// Turn off any errorserror_reporting(0);// Your Ip address / hostname$site = "google.com";// Port to check ex. 80 is http | 21 is ftp etc.$port = "80";// Check if server is up or down$sock = fsockopen( "$site", "$port", $errno, $errstr, 5 ); if ( ! $sock ) { echo("<font color=\"red\"><b>DOWN</b></font>");} else { echo("<font color=\"green\"><b>UP</b></font>");}