As I quite frequently say,
The <!-- and //--> comment (hiding) tags have not been necessary since IE3 (i.e. since September 1997). If you see these in some published script it is a warning that (as in this case) you are looking at ancient and perhaps unreliable code.
Surely Chrome and Opera do not recognise document.all? That is IE specific.
All the code given in this post has been tested and is intended to address the question asked.
Unless stated otherwise it is not just a demonstration.
Last edited by Philip M; 11-07-2012 at 09:10 AM..