RE: Alternate Colors in Rows ($r=!$r)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[snip]
 
> if($r = !$r)
> 
> it is a conditional test.
> 
> ? foo : bar;
> 
> ...is the ternary operation. Just wanted to clean up the usage there.

Did I miss something? The code I saw was the following:

    <TR class=<?php echo ($r = !$r) ? "dataRow1" : "dataRow2"; ?> >

And that is definitely using the ternary operator. 
[/snip]

No, you didn't miss anything. I was just pointing out that the ternary
operation starts with the ?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux