Forums

IE CSS Hover & Selected States

Hi all,
I’m having some trouble with IE 7 and css hovers/selects. On my menu, when you hover over an item, a hover is applied that displays a border. When you’re on that page, the same blue border is solid (selected). This works perfectly in Firefox, but as usual IE is having some issues. First, IE does not want to display the hover border. I corrected this by adding a position: absolute; element. However, the selected state does not want to display. When the position: absolute is applied to the selected state, it appears, however, extends the entire length of the word and spacing. In addition, when hovered over, the selected state does not disappear, it is just pushed down. Here is the code in question:

Tips

Categories

We have a pretty good* newsletter.

Email Address

CSS-Tricks* is created, written by, and maintained by Chris Coyier and a team of swell people. It is built on WordPress, hosted by Media Temple, and the assets are served by MaxCDN. The fonts are Source Sans Pro and Source Code Pro. It is made possible through sponsorships from products and services we like.