archive for my answer, and believe I know how this is supposed to
work, I just cannot figure out why it is not working for me. I want
to pass an extra keyword parameter to my view that contains a filter
value, but it is not getting passed. Here is the urls.py entry:
(r'requirementlibrary/(?P<id>\d+)/requirements/$', 'requirements',
{'filter_param':'library'}),
and the view:
def requirements(request, id=None, filter_param=None):
print filter_param
the filter_param is always "None"
Here is the example from the django docs:
(r'^blog/(?P<year>\d{4})/$', 'year_archive', {'foo': 'bar'}),
In this example, for a request to /blog/2005/, Django will call the
blog.views.year_archive() view, passing it these keyword arguments:
year='2005', foo='bar'
Anyone know what I a missing?
-richard
--
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+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
No comments:
Post a Comment