The first script demonstrates how to manipulate text on the status bar. When you move the cursor over a hyperlink, the status bar shows the destination URL. This script allows you to easily replace the URL address with whatever you'd like. A common use is to add a brief description of the URL or brief title.
The normal HTML code for a hyperlink might be something like this:
To display something on the status bar when the mouse is moved over this link, you need to add a little more:
The above code will produce a link like this link. Don't click on it now because it doesn't go anywhere.
This is script requires a little more coding than the one above:
Pop-up windows can be useful in some cases.If you'd like to pop-up a message window when clicking on a link it's very simple. Try clicking here. To understand, take a look at how the link is coded.
It is also possible to pop-up a message when a button is clicked:
<FORM> <INPUT TYPE=BUTTON VALUE="Click me" onClick="alert('your message here')"> </FORM>
You might have noticed that the syntax used in each of the scripts is very different. While the first one was embedded within another tag (<A HREF=...> in this case), the second one was within a SCRIPT tag. Another difference is that the first one is executed only when the specified event (MouseOver in this case) occurred whereas the second one is executed as soon as it is encountered in the HTML document.