2 * The general idea is from the following A List Apart article:
3 * http://www.alistapart.com/articles/zebratables/
5 * The structure is inspired by the code fragment they supply, but the
6 * code here is significantly cleaner. It also colors every two lines
7 * rather than every line, since XVM uses two rows for each item.
10 function stripe(table, darkClass, lightClass) {
11 for (var i = 0; i < table.rows.length; i++ ) {
12 /* The header row should be light; the next two are dark. */
13 if (i%4 == 1 || i%4 == 2)
14 table.rows[i].className += ' ' + darkClass;
16 table.rows[i].className += ' ' + lightClass;