Infinite Possibilities
Infinite Possibilities

Reputation: 7466

Internet explorer css with anchor tag

I was checking some posts on this site, but still can't find the solution.
Here's my html:

<div id="id1">
  <div id="id2">
    <div id="id3">
      <a id="id4" class="divItem">
        text
      </a>
    </div>
  </div>
</div>

and css:

#id1 {
width:960px;
margin:auto;
}

#id2 {
position:relative;
font-family:Calibri;
}

#id3 {
float:right;
position:relative;
margin-bottom:10px;
font-size:12px;
color:#5E666D;
}

.divItem {
float:left;
margin-right:10px;
}

a.divItem:hover {
color:#AD8E5A;
font-size:11px;
}

But the hover on divItem doesn't appear in internet explorer, only in safari and firefox and chrome.

Upvotes: 1

Views: 307

Answers (1)

Pekka
Pekka

Reputation: 449415

Internet Explorer 6 can interpret :hover only on a elements with a href attribute. You are missing the attribute.

There's a fix that makes :hover work as it does in other browsers.

Upvotes: 2

Related Questions