I have nine sets of color schemes that I want to apply to a sequence of divs. Using :nth-child(1), :nth-child(2)... works for the first nine, but I\'d like the
:nth-child(1), :nth-child(2)...
If you mean you need to apply different rules to every nine consecutive elements, you have to use these nine selectors:
:nth-child(9n+1) :nth-child(9n+2) :nth-child(9n+3) :nth-child(9n+4) :nth-child(9n+5) :nth-child(9n+6) :nth-child(9n+7) :nth-child(9n+8) :nth-child(9n+9) /* Or :nth-child(9n) */