[Zope] Alternating Row Colors

Darin Lee LEEDM@state.mi.us
Mon, 22 Jan 2001 08:54:49 -0500


Lee,

Alternating row colors are very easy in Zope because of the variables 'sequence-odd' and 'sequence-even' defined by the <dtml-in> tag.

A super quick example:

<table bgcolor="#ffffff">
<dtml-in some_list>
 <tr <dtml-if sequence-odd>bgcolor="#EEEEEE"</dtml-if>>
   <td>Your cell data here</td>
 </tr>
</table>

You can code variations on this to get what you need.

-Darin