On Dec 23, 10:47 pm, Jeroen Ruigrok van der Werven
<asmo... in-
nomine.org> wrote:
> -On [20071224 04:12], jerryji (jerryji1... gmail.com) wrote:
>
> >Sorry for this very newbie question: how to iterate
N times over an
> >integer variable = N in Genshi?
>
> I think you need something like:
>
> <py:for each="num in range(var)">
> <p>$num</p>
> </py:for>
>
> Where var is your integer variable.
Or if "var" is potentially large you can use
xrange(var) instead which
just creates an iterable object while range(var) builds a
list of that
length.
-- Matt
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "Genshi" group.
To post to this group, send email to genshi googlegroups.com
To unsubscribe from this group, send email to
genshi-unsubscribe googlegroups.com
For more options, visit this group at http://gr
oups.google.com/group/genshi?hl=en
-~----------~----~----~----~------~----~------~--~---
|