It is written in PHP, a widely supported scripting/programming language.
Someone on another forum posted this:-
Put a file up on your private server, for example foo.gif. Then, use simple code like this to check if the server is up or down:
<script type="text/javascript">
var url = "http://www.yourprivateserver.com/foo.gif";
var img = new Image();
img.src = url;
img.onload = function()
{
// If the server is up, do this.
alert("Server is up!");
}
img.onerror = function()
{
// If the server is down, do that.
alert("Server is down!");
}
</script>
Yes, that works fine. However, it will fail to display the server status if the user has JavaScript turned off. Also, if something happens to the image you are linking to (you accidentally remove it, rename it or relocate it), the script will assume that the server is down.
The basic idea in that example is to try and link to an image on your server. If it fails one can assume that the server is down. A really simple (and not so glamorous) way to do this without any scripting is to make a normal link to an image on your page:
<img src="http://www.myserver.com/image/image.gif" />
Then write something like “If you can see this image my server is online. If you can´t see it my server is offline.”

However will it work with a password protected server - my private server (apache) is actualy running on my home PC, so for security it is always password protected, and that includes my root htdocs directory.
What kind of protection are we talking about? .htaccess?
Do you think it would be to much of a security risk to have a small unprotected directory (presumably that would have to be the root - entry point) just to hold an image for the purposes of checking, and then to password protect the rest of the site?
I think the image has to be inside a folder that is NOT protected. You could setup a separate folder for the image and leave the rest of the folders protected.
What do you think, itsyM, would the security risk be too big?
As long as you have your Apache configured correctly (security-wise), there should be no problems.