CSS :last-of-type 选择器
2019-03-25 21:12
127 查看
HTML 用法
<body> <h1>:last-of-type选择器匹配元素其父级是特定类型的最后一个子元素</h1> <h3>实例:指定其父级的最后一个p元素的背景色</h3> <p>www.semi-warm.com</p> <p>www.semi-warm.com</p> <p>半暖茶港</p> </body>
CSS 用法
p:last-of-type { background:#ff0000; }
相关文章推荐
- 【Web前端】CSS 选择器之 last-child 与 last-of-type
- CSS 选择器 :last-child与:last-of-type的区别
- CSS nth-child、first-child、last-child、nth-of-type、first-of-type和last-of-type选择器使用
- CSS nth-child、first-child、last-child、nth-of-type、first-of-type和last-of-type选择器使用
- CSS3伪类选择器:nth-child(n)及:nth-of-type(n)使用区别探究总结
- 【CSS3】---last-of-type选择器+nth-last-of-type(n)选择器
- first-child first-of-type last-child last-of-type 伪类选择器总结
- last-of-type选择器
- 【CSS3】---last-of-type选择器+nth-last-of-type(n)选择器
- 【CSS3】---last-of-type选择器+nth-last-of-type(n)选择器
- CSS :only-of-type 选择器
- :last-of-type | CSS属性参考
- jQuery选择器中last-of-type和first-of-type效果案例
- css伪类选择器之:first-child和:first-of-type
- jQuery选择器中last-of-type和first-of-type效果案例
- 选择器的使用(nth-of-type和nth-last-of-type选择器)
- css:nth-of-type()选择器用法
- css 伪类选择器 :nth-child(n) 与:nth-of-type(n)的区别
- 【CSS3】使用:not(:last-of-type)简化你的css代码
- css3 - 选择器first-child、last-child、nth-child、nth-last-child、nth-of-type