我有site 即使在 IE 中也能正常显示。然而,在 Opera 11.62 中,每当我将鼠标悬停在导航栏的链接上时,都会出现一个非常奇怪的错误。为什么会出现这种情况?这很烦人。 还有一件非常奇怪的事情正在发生,如果我调整浏览器窗口的大小,使最后一个链接超出页面,而不是只有最后一个链接在悬停时显示正常,但其他两个仍然损坏。
最佳答案
将此行代码添加到a:hover
height: 100%;
所以你得到:
a:hover {
background: -o-linear-gradient(top, #93C9ED 0px, #76B4E1 100%) transparent;
border-bottom: medium none currentColor;
border-left: 1px solid #1C5E9C;
border-right: 1px solid #1C5E9C;
border-top: 1px solid #1C5E9C;
color: #275D8B;
height: 100%;
}
关于CSS 悬停问题仅在 Opera 中出现,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10767140/