Welcome Guest, Not a member yet? Register   Sign In
Alternator function inside template loop
#3

[eluser]guidorossi[/eluser]
But that way you can't also use the template class, right?
By not using the template class I can simply do:
Code:
<?php if($articles): foreach($articles as $article): ?>
            <ul class="&lt;?=alternator('even', 'odd');?&gt;">
                <li class="article_name">&lt;?=$article->name?&gt;</li>
                <li class="article_descr">&lt;?=$article->description?&gt;</li>
            </ul>
&lt;?php endforeach; endif;?&gt;

But as I was coding all the views using template, I just want to use for this too...


Messages In This Thread
Alternator function inside template loop - by El Forum - 05-29-2011, 12:34 PM
Alternator function inside template loop - by El Forum - 05-29-2011, 06:51 PM
Alternator function inside template loop - by El Forum - 05-29-2011, 07:47 PM
Alternator function inside template loop - by El Forum - 05-29-2011, 07:55 PM
Alternator function inside template loop - by El Forum - 05-29-2011, 09:18 PM
Alternator function inside template loop - by El Forum - 05-29-2011, 10:05 PM
Alternator function inside template loop - by El Forum - 05-30-2011, 09:48 AM
Alternator function inside template loop - by El Forum - 05-30-2011, 10:42 AM
Alternator function inside template loop - by El Forum - 05-31-2011, 12:18 AM
Alternator function inside template loop - by El Forum - 05-31-2011, 12:30 AM



Theme © iAndrew 2016 - Forum software by © MyBB