E:last-child { sRules }
有效的代码:
p:last-child{color:#f00;}
	我是一个标题
	我是一个p
 
						无效的代码:
p:last-child{color:#f00;}
	我是一个p
	我是一个标题
 
						在上述代码中,如果我们要设置第一个li的样式,那么代码应该写成li:first-child{sRules},而不是ul:first-child{sRules}。
| IE | Firefox | Chrome | Safari | Opera | iOS Safari | Android Browser | Android Chrome | 
|---|---|---|---|---|---|---|---|
| 6.0-8.0 | 2.0+ | 4.0+ | 3.1+ | 3.5+ | 3.2+ | 2.1+ | 18.0+ | 
| IE9.0+ |