Also, see Flipper for more discussion about this kind of thing.my @BGColors = ('#dddddd', '#ffffff'); for (1..10){ # As you loop through a database query result or somethin +g print qq{ <tr bgcolor="$BGColors[$flip = !$flip]"> <td>$_</td> </tr> }; }
Russ
Brainbench 'Most Valuable Professional' for Perl
In reply to Re: alternating row colors
by Russ
in thread alternating row colors
by qball
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |