我正在查看此站点上的一些帖子,但仍然找不到解决方案。
这是我的 HTML:
<div id="id1">
<div id="id2">
<div id="id3">
<a id="id4" class="divItem">
text
</a>
</div>
</div>
</div>
和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;
}
但是 divItem 上的悬停不会出现在 internet explorer 中,只会出现在 safari 和 firefox 以及 chrome 中。
最佳答案
Internet Explorer 6 只能在具有 href
属性的 a
元素上解释 :hover
。您缺少该属性。
有一个 fix这使得 :hover
像在其他浏览器中一样工作。
关于css - 带有 anchor 标记的 Internet Explorer CSS,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4086583/