What is the proper syntax for changing the table cell background color of every-other div?
Code example:
<table>
<div id="alternator">
<tr>
//stuff here
</tr>
<tbody>
<tr>
<td>
<table>
//stuff here
</table>
</td>
</tr>
</tbody>
</div>
</table>
To explain, I have a part of my table wrapped in a Div with the id of ALTERNATOR
For every other ALTERNATOR that appears on the page, I want to change the background color of the table cells inside
Something like:
(#Alternator:odd).AllTableCellsInside().attr(background-color, "grey")
Looks like the perfect use case for the
:oddselector: http://api.jquery.com/odd-selector/