Re: Alternate Colors in Rows
| From: | Jon Anderson | Date: | Wed, 03 Oct 2007 19:02:56 +0000 |
| Subject: | Re: Alternate Colors in Rows | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-262703@lists.php.net to get a copy of this message | ||
Steve Marquez wrote:
I am attempting to alternate the colors of the container DIV. Anyone know how to do this?I've used variants of this: <?php while ($condition): ?> <div style="background-color: #<?= ($i++%2) ? 'ffffff' : 'eeeeee' ?>;"> <?php endwhile ?> jon