On Wed, 2008-09-10 at 01:19 -0700, aleray wrote:
[...]
> This last line is unuseful for my project because I want to use slugs
> instead of id's, so I try :
> 
>         <a href="{% url news-cat general %}">categorie</a>
> 
> And then I get an error :
> 
> NoReverseMatch: Reverse for 'www.news-cat' with arguments '('',)' and
> keyword arguments '{}' not found.
> 
> What is wrong ?

The way you've written your url tag, it's trying to extract the argument
from a template variable called "general". Such a variable probably
doesn't exist, so it ends up resolving to the empty string. Instead, you
want to write

        {% url news-cat "general" %}
        
Regards,
Malcolm



--~--~---------~--~----~------------~-------~--~----~
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?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to