Inside Technique : Hover Effects
Our solution is similar in concept to the image rollover effect. With the image rollover effect, you detect the onmouseover and onmouseout event of an image by wrapping it in an link. The link contains a small script that changes the images source. For the rollover effect to work effectively in Netscape Navigator, the image must be the same size as the original. This is because Netscape Navigator cannot dynamicalliy adjust the document based on any changes in content. Internet Explorer 4.0 can reflow the document allowing the image to change in size.
When examining adding link effects to text you have similar limitations. In Internet Explorer, the hover effect can change any aspect of the link, and the page automatically adjusts. For example, if you change the font-size of the link when the mouse is over it, the document ajusts itself based on the new size of the text. In Netscape Navigator, since the page cannot relayout, the hover effect should not do anything that changes its size.
© 1997-2000 InsideDHTML.com, LLC. All rights reserved.