Adam Hoscilo wrote:
> I get this error: len() of unsized object
> while doing nested for loops in the template:
> {% for entry in object_list %}
>     {% for category in entry.categories %}
>         {{ category.name }}
>     {% endfor %}
>     {{ entry.get_absolute_url }}
> {% endfor %}
> 
> entry.categries is ManyToManyField

Then you want entry.categories.all in your template.

-- 
--Max Battcher--
http://www.worldmaker.net/
"I'm gonna win, trust in me / I have come to save this world / and in 
the end I'll get the grrrl!" --Machinae Supremacy, Hero (Promo Track)

--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to