1.奇偶属性:
/*奇数*/
ul li:nth-child(odd){
background-color: green;
}
/*偶数*/
ul li:nth-child(even){
background-color: red;
}
2.
1.奇偶属性:
/*奇数*/
ul li:nth-child(odd){
background-color: green;
}
/*偶数*/
ul li:nth-child(even){
background-color: red;
}
2.
转载于:https://www.cnblogs.com/xiao-peng-ji/p/11474514.html