1👍
✅
URLs don’t match on query parameters. They take the path (everything before the ?) from the request, and attempts to match against your URL regex.
What you need to do is handle the GET parameters in your view, and route from there to other functions if you need to. Example:
request: http://www.mydomain.com/signup/?password=goodbye
(r'^signup/$','abc.wall.views.signup_front')
def signup_front(self, request):
query_param = request.GET.get('password', None)
if query_param == "goodbye":
return signup_goodbye(request)
# other stuff here
def signup_goodbye(self, request):
# blah
# return render_to_response(..)
- [Answered ]-Python Django "and/or" searching in database
- [Answered ]-Django Form error "Enter a list of values" for ManyToMany field
Source:stackexchange.com