[jQuery] Zebra striping in tables
Hi,
I know how to do some 'zebra-striping' on tables with jQ, but i have a
little problem.
I have some (unknown amount) tables om a page and I want to 'stripe'
the tables seperately, so that all striping is the same in each table.
With a simple:
$("table tr:even").css("background", "#cccccc") the rows are counted
over all the tables and I want to start counting (for even and odd
rows) for every table, so i tought:
$("table").each(function() {
// how to get the rows here???
})
How do I do this? (I do not know on forehand how many or which tables
are on the page....)