diff options
author | Pierre-Yves Chibon <pingou@pingoured.fr> | 2012-04-05 20:52:53 +0200 |
---|---|---|
committer | Pierre-Yves Chibon <pingou@pingoured.fr> | 2012-04-05 20:52:53 +0200 |
commit | 9462600628677b842c7e69d47a07f0b4581a897f (patch) | |
tree | 3f30620dc041a5ac703538ed8e60be0ccb9dacd8 | |
parent | f0d0d2c269e6a8274cd64f55210d7b104ab8bb81 (diff) | |
download | hyperkitty-9462600628677b842c7e69d47a07f0b4581a897f.tar.gz hyperkitty-9462600628677b842c7e69d47a07f0b4581a897f.tar.xz hyperkitty-9462600628677b842c7e69d47a07f0b4581a897f.zip |
The order of the regex matters, urls with a trailing slash should be before the one without
-rw-r--r-- | urls.py | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -32,13 +32,14 @@ urlpatterns = patterns('', # Search #url(r'^search$', 'views.pages.search'), # If page number is present in URL - url(r'^search/(?P<mlist_fqdn>.*@.*)\/(?P<target>.*)\/(?P<keyword>.*)\/(?P<page>\d+)$', 'views.pages.search_keyword'), url(r'^search/(?P<mlist_fqdn>.*@.*)\/(?P<target>.*)\/(?P<keyword>.*)\/(?P<page>\d+)/$', 'views.pages.search_keyword'), + url(r'^search/(?P<mlist_fqdn>.*@.*)\/(?P<target>.*)\/(?P<keyword>.*)\/(?P<page>\d+)$', 'views.pages.search_keyword'), # Show the first page as default when no page number is present in URL - url(r'^search/(?P<mlist_fqdn>.*@.*)\/(?P<target>.*)\/(?P<keyword>.*)$', 'views.pages.search_keyword'), url(r'^search/(?P<mlist_fqdn>.*@.*)\/(?P<target>.*)\/(?P<keyword>.*)/$', 'views.pages.search_keyword'), - url(r'^search/(?P<mlist_fqdn>.*@.*)$', 'views.pages.search'), + url(r'^search/(?P<mlist_fqdn>.*@.*)\/(?P<target>.*)\/(?P<keyword>.*)$', 'views.pages.search_keyword'), + url(r'^search/(?P<mlist_fqdn>.*@.*)/$', 'views.pages.search'), + url(r'^search/(?P<mlist_fqdn>.*@.*)$', 'views.pages.search'), url(r'^tag/(?P<mlist_fqdn>.*@.*)\/(?P<tag>.*)$', 'views.pages.search_tag'), # mockups: url(r'^mockup/$', 'views.mockup.index'), |