Sunday, May 12, 2013

Yet Another NoReverseMatch Error

I have an app within my project called popular_keywords. 

Within urls.py I have this:

urlpatterns = patterns("apps.popular_keywords.views",
                       url("^%keyword/(?P<keyword>.*)%s$" % _slashes, "matching_items_list", name="matching_items")
)


Within views.py I have this function:

def matching_items_list(request, keyword=None, template="popular_keywords/keyword_matched_list.html")



In my template I have this:

<a href="{% url "matching_items" keyword=keyword %}">


The problem is when I view my page I find this:


NoReverseMatch at /

Reverse for 'matching_items' with arguments '()' and keyword arguments '{u'keyword': 'Cake'}' not found.

I thought I had my bases covered, but as a Django noob, I would appreciate help on whatever silly thing I missed. Please let me know if I need to provide more information.

Thanks.





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

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate