Okay, no takers...... I have given it a little more thought and would presume we would have to have a little circle thing going on.
In order to establish whether or not the server was working the server would have to be queried, eg by typing the URL into your chosen browser & loading the website. Obviously this would not happen if the server had issues, so initially when a person requested your URL, they would first have to go via the backup server which would then decide whether or not they should go to the regular site or stay on the back up server.
Sounds easy when you put it like that, but how would you go about putting this into practise?!