-
Notifications
You must be signed in to change notification settings - Fork 88
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use reverse so more redirects work when MapIt is mounted on a subpath
If you've included MapIt in another Django project, e.g. with: urlpatterns += patterns('', (r'^mapit/', include('mapit.urls')), ) ... then some of the views that returned a redirect to a URL constructed with string formatting would redirect to a path that didn't include the 'mapit/' prefix. If these paths are constructed with reverse() instead, it works properly. This also introduces some new URL pattern names, so the URL patterns can be referred to more concisely.
- Loading branch information
Showing
3 changed files
with
32 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters