RE: [PHP-WIN] Alternate table rows

2002-10-04 Thread Davy Obdam
Hi Dash, Thanks it works! Best regards, Davy Obdam mailto:[EMAIL PROTECTED] -Original Message- From: Dash McElroy [mailto:[EMAIL PROTECTED]] Sent: Friday, October 04, 2002 1:53 AM To: 'Davy Obdam'; [EMAIL PROTECTED] Subject: RE: [PHP-WIN] Alternate table rows phpMyAdm

RE: [PHP-WIN] Alternate table rows

2002-10-03 Thread Rich Gray
Hi Davy Use the modulo function to switch colours eg echo '\n'; for ($i=0;$i'. '... etc etc See what I mean? HTH Rich -Original Message- From: Davy Obdam [mailto:[EMAIL PROTECTED]] Sent: 03 October 2002 16:48 To: Php-Windows Mailing Subject: [PHP-WIN] Alternate table ro

RE: [PHP-WIN] Alternate table rows

2002-10-03 Thread Dash McElroy
phpMyAdmin does it like this: $bgcolor = ($i % 2) ? $cfg['BgcolorOne'] : $cfg['BgcolorTwo']; Obviously you'd have your $cfg['BgcolorOne'] and $cfg['BgcolorTwo'] set to different colors, or change those variables right there. -Dash -Original Message- From: Davy Obdam [mailt

RE: [PHP-WIN] Alternate table rows

2002-10-03 Thread Flint Doungchak
Davy, Try using the modulus function to determine if you're in an odd row or an even row. You can then apply the one row color for one row and another for another row. http://www.php.net/manual/en/language.operators.arithmetic.php You'll need to create your look so that it run per row instead