[eluser]laegnur[/eluser]
Hi.
I'm new to CodeIgniter.
In a view I have the next code
Code:
<?php
foreach ($a as $b)
{
?>
<?php
echo '<div>'.$b->field1.'-'.$b->field2.'</div>'."\n";
?>
<?php
}
?>
How can I identified the first "foreach" element, to apply a special css class to it.
Sorry for my bad english...
Edit: Thanks pistolPete and tomcode for your answers.