]> git.openstreetmap.org Git - osqa.git/blobdiff - forum/views/readers.py
Fixes some problems with urlquoting on seraches.
[osqa.git] / forum / views / readers.py
index f756a9468f7c12042ec8d34c6104b5b177ec19d4..6e75b378a1572b2900f78933db16bdeab4157f69 100644 (file)
@@ -120,9 +120,9 @@ def search(request):
         if not keywords:
             return HttpResponseRedirect(reverse(index))
         if search_type == 'tag':
-            return HttpResponseRedirect(reverse('tags') + '?q=%s' % (keywords.strip()))
+            return HttpResponseRedirect(reverse('tags') + '?q=%s' % urlquote(keywords.strip()))
         elif search_type == "user":
-            return HttpResponseRedirect(reverse('users') + '?q=%s' % (keywords.strip()))
+            return HttpResponseRedirect(reverse('users') + '?q=%s' % urlquote(keywords.strip()))
         elif search_type == "question":
             return question_search(request, keywords)
     else: