如何解决相邻的兄弟选择器和:在Chrome 10中的伪元素之前
| 这是一个奇怪的。 http://www.madebypaz.com/profile上的“ 0”将“ 1”伪元素用于图表的注释(ABC和图像)。我这样使用相邻的兄弟选择器:#profiletext ol li:before {
content: \'A\';
}
#profiletext ol li+li:before {
content: \'B\';
}
#profiletext ol li+li+li:before {
content: \'C\';
}
#profiletext ol li+li+li+li:before {
content: \'\';
}
#profiletext ol li+li+li+li {
background: url(\'/wp-content/themes/paz2010/images/sweet-spot.png\') no-repeat;
margin-left: 0;
padding-left: 38px;
}
#profiletext ol li {
height: 30px;
margin-left: 10px;
}
这可能不是最优雅的解决方案,但是它在包括Chrome在内的所有浏览器中均能完美运行,直到有人向我指出它在Chrome 10中损坏。在Chrome 10中,它显示AAA并在鼠标悬停时更改为正确的字符。这很好奇,因为甚至没有定义:hover样式!
这是此内容的屏幕记录:http://cl.ly/0E170v1Z0O2E0f3F0j0d
为什么会这样,我该如何解决?有没有更好的方法来达到相同的结果?
任何指针,不胜感激!
解决方法
这在Chrome 16上可以正常运行-需要进行简单更新。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。