Here's one way:
<TABLE>
<CFSET bgcolor="ffffff"> <!--- this is your starting color --->
<CFOUTPUT query="myQuery">
<TR bgcolor="#bgcolor#">
<TD>#myData#<TD>
</TR>
<CFIF bgcolor="ffffff"> <!--- if bgcolor is equal to your starting
color --->
<CFSET bgcolor="fefefe"> <!--- set bgcolor to your second
color --->
<CFELSE>
<CFSET bgcolor="ffffff"> <!--- otherwise set bgcolor back to
your starting color --->
</CFIF>
</CFOUTPUT>
</TABLE>
Hope it helps!
- - - Jeanne
----- Original Message -----
From: Joshua Tipton <[EMAIL PROTECTED]>
To: CF-Talk <[EMAIL PROTECTED]>
Sent: Thursday, April 26, 2001 2:40 PM
Subject: Row Color
> How do I make a tr tag change for every row. I would like alternating row
> colors.
>
> Joshua Tipton
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists