css - 除了第一个 child 之外的所有东西

标签 css css-selectors

我知道选择器 :not() 但它不起作用,例如 tr:not(tr:first-child):hover。我想设置其他 tr 的样式,但不是第一个,因为它包含标题。如何在不使用 idclass 的情况下执行此操作?

最佳答案

您只能使用 simple selectors:not() 中尝试

tr:not(:first-child)

http://jsfiddle.net/mowglisanu/Sn7Uw/

关于css - 除了第一个 child 之外的所有东西,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19261508/

相关文章:

html - 让子div占据100%的高度

html - xs 中的 Bootstrap 网格

css - 无法使第 n 个 child 与 IE8 一起工作

css - 如何选择::after元素?

html - 选择导航栏中的第一个 <li>

CSS3 目标前一个元素?

javascript - 创建一致的简单横幅文本动画

css - 避免边框重叠 CSS

php - 使用 JQuery 加载函数时,Internet Explorer 中不显示背景

html - 通过同一属性的一组特定值选择第一个元素