2009/8/10 elminio <wgruszczyn...@gmail.com>:
>
> Hello,
> Is it possible to insert to the template for example 10 checkboxes
>
> I know syntax of iterating through objects in list and do some task
> for each item but Im interested in normal for loop
> like
>
> for i in xrang(10):
>    insert checkbox
>
> thanks for reply
>
>
You can create a template tag to do the work for you and pass the
number of items you want as a parameter. You can also create using
javascript and use a django template variable to set the counter.


-- 
Antoni Aloy López
Blog: http://trespams.com
Site: http://apsl.net

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to