a problem about section

Author Message

xiao jc

Thursday 20 May 2004 8:49:36 pm

juset like:
<section loop=$loop>
$i++;
</sction>

how can i do this?
thanks very much

Ole Morten Halvorsen

Friday 21 May 2004 12:20:31 am

Hi,

From the doc:
Each time the section iterates it sets four template variables in the new namespace. The variables are index, number, key and item.

index - is a number which starts at 0 and increases for each iteration.

Try this:

{section loop=$loop}
    {$:index}
{/section}

More info here: http://ez.no/ez_publish/documentation/reference/template_functions/program_flow/section

Senior Software Engineer - Vision with Technology

http://www.visionwt.com
http://www.omh.cc
http://www.twitter.com/omh

eZ Certified Developer
http://ez.no/certification/verify/358441
http://ez.no/certification/verify/272578

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.