How to hide or change the message displayed in the status bar
Newer browsers (such as FireFox and IE 7) do not allow you to change the status bar. The contents of this article should therefore be regarded as depreciated as it is applicable only to older browsers.
You can configure newer browsers to allow the status bar message to be changed, but this only allows YOU to see it, not your visitors.
In Internet Explorer: Tools → Internet Options → Security tab → Select "Internet" then click on "Custom level ..." → Scroll down and under "Scripting" enable the option to "Allow status bar updates via script" → [OK] → [OK]
Normally when the mouse is moved over a link the status bar changes to display the target (or address) of that link. For example place the cursor over www.cryer.co.uk and the link 'http://www.cryer.co.uk/' is shown in the browser status bar. It is possible (and sometimes desirable) to change this.
Making it work for most browsers
Firstly consider the HTML for the above link:
To change what is shown in the status bar requires adding an '
onMouseOut' event handlers. The '
event handler needs to set the status bar to show what we want and the '
to clear it. Thus:
<a href="http://www.cryer.co.uk" onMouseOver="window.status='Cryer Internet Resources'; return true" onMouseOut="window.status='';return true">www.cryer.co.uk</a>
This produces: www.cryer.co.uk, which shows ''Cryer Internet Resources" in the status bar when the cursor is moved over the link.
Making it work for the rest
Unfortunately if you are using Netscape Navigator version 6 or Opera (or possibly some earlier versions of Internet Explorer) this doesn't quite work! Although no scripting error is reported (because there isn't one) the status bar stays unchanged.
What is required is a means to delay updating the status bar - so that our intended update happens after Netscape Navigator has updated it with the normal URL. This can be accomplished with a simple timeout. A separate function is introduced here in order to keep the logic code event handler code short:
onMouseOver="SetStatus('Cryer Internet Resources'); return true"
This produces: www.cryer.co.uk, which shows "Cryer Internet Resources" in the status bar when the cursor is moved over the link and works equally well for Internet Explorer and Netscape Navigator.
A word of caution: It is often useful for a someone surfing the net to be able to see where a link will take them, so don't over use.