Daniel Glazman
Ian Hickson
.green { background-color : lime ! important; }
ul > li:not(:nth-last-child(odd)) { background-color : red }
ol > li:not(:nth-last-child(even)) { background-color : red }
table.t1 tr:not(:nth-last-child(-n+4)) { background-color : red }
table.t2 td:not(:nth-last-child(3n+1)) { background-color : red }
table.t1 td, table.t2 td { border : thin black solid }
- This first list item should have a green background
- Second list item
- This third list item should have a green background
- Fourth list item
- This fifth list item should have a green background
- Sixth list item
- First list item
- This second list item should have a green background
- Third list item
- This fourth list item should have a green background
- Fifth list item
- This sixth list item should have a green background
Green row : 1.1 |
1.2 |
1.3 |
Green row : 2.1 |
2.2 |
2.3 |
3.1 |
3.2 |
3.3 |
4.1 |
4.2 |
4.3 |
5.1 |
5.2 |
5.3 |
6.1 |
6.2 |
6.3 |
green cell |
1.2 |
green cell |
green cell |
1.5 |
green cell |
green cell |
1.8 |
green cell |
2.2 |
green cell |
green cell |
2.5 |
green cell |
green cell |
2.8 |
green cell |
3.2 |
green cell |
green cell |
3.5 |
green cell |
green cell |
3.8 |