Hello, I would like to create a list filter in my site just like the one in the admin app. If I am correct I can do by adding a paramter to my url.
In my view I can capture the parameter with request.GET.get ('category', '') and filter my object_list. Everything works just fine but it doesn't feel right. If I look to the admin is see that for example spaces are replaced by a '+' sign and & is replaced by '%26'. I have just white spaces and the & sign in my parameters. To avoid this I have put the urlencode filter in my template. Example: {% for category in category_list %} <a href="?category={{ category.name|urlencode }}">{{ category.name }}</ a><br/> {% endfor %} The & sign is perfectly replaced by %26, but the white spaces are not being replaced by a '+'. As far as I know I just use normal url patterns. (r'^aanbiedingen/$', test), I have struggled with tis issue for a while now so I thought I will drop my question here.... --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---