>?php foreach ($things as $row=>$thing): ?>
  <tr <?php e(($row%2)?"class='even'":"class='odd'") ?></tr>
     <td><?php e($thing['field']) ?></td>
  </tr>
<?php endforeach; ?>

see if that gives you a hint

On 12/4/06, mschwer <[EMAIL PROTECTED]> wrote:
>
> Hello!
>
> To retrieve the Output on my views template i used the normal foreach()
> loop.
>
> <? foreach ($Programms as $programm): ?>
>         <tr>
>                 <td><? echo $programm['Programm']['wann']; ?></td>
>                 <td><? echo $programm['Programm']['wo']; ?></td>
>                 <td><? echo $programm['Programm']['werwas']; ?></td>
>                 <td><? echo $programm['Programm']['whatelse']; ?></td>
>         </tr>
>         <? endforeach; ?>
>
> The defined row tag is <tr class='altRow'>. Now I wanna have in the
> output that the first row is starting just with <tr> and the second
> should be starting with <tr class='altRow'>.
>
> How can i do that?
>
> greetz
> Michael
>
>
> >
>


-- 
==
S. DeVore
(the old fart) the advice is free, the lack of crankiness will cost you

--~--~---------~--~----~------------~-------~--~----~
 You received this message because you are subscribed to the Google Groups 
"Cake PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to