Cut & Paste
|
Description: An alternate version of the popular rollover effect script that checks a check box instead when the mouse moves over a link. Not too useful, although quite amusing.
Example:
Directions: Simply insert the below into the <body> section of your page where you want the links to appear:
Configuring the script: The script used to create the rollover effect is actually very short and simple- the majority of the code are HTML codes used to render the checkboxes. Anyhow, the key thing to understand is that each <a> tag contains the code:
<a href="test.htm" onMouseover="rollovercheck(0)" onMouseout="rolloutcheck(0)">
The integer 0 inside the parenthesis indicates that when the mouse moves over this link, it should check the first check box (JavaScripts counts from 0, remember?). Therefore, if you have 100 links, the hundredth link will contain the code:
<a href="test.htm" onMouseover="rollovercheck(99)" onMouseout="rolloutcheck(99)">'
so when the mouse moves over it, the script correctly checks the box beside it.
Play around with the code, and you'll see what I mean.