On 14/06/2015 3:31 AM, [email protected] wrote:
Trying to figure out how to change the url for the search results page.

I see
|
<form action="{% url "search" %}"
|

and that forms domain.com/search_results.html/?q=query

but I would much rather have: domain.com/search?=query

Been searching thru docs and can't seem to find what I need to do that, can someone point in the right direction?

The URL 'search' is defined here:
https://github.com/stephenmcd/mezzanine/blob/master/mezzanine/core/urls.py#L24

which uses the view named search defined here:
https://github.com/stephenmcd/mezzanine/blob/master/mezzanine/core/views.py#L106

Which uses a template called search_results.html

I suspect if you look through that function you can probably work out how it's changing the URL in your browser, and if you want to change it, you may need to copy and rename the template, and then override the url to pass in your template name instead.

HTH. HAND.

Seeya. Danny.

--
You received this message because you are subscribed to the Google Groups "Mezzanine 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to