Commits

David Chambers  committed 3782e9e

Added `TAGS_PAGE` setting.

  • Participants
  • Parent commits 2da7e08

Comments (0)

Files changed (2)

File settings/defaults.py

 
 CONTACT_FORM = True
 
+TAGS_PAGE = True
+
 FEED_MAX_POSTS = 20
 
 CACHE_SECONDS = 15 * 60 # set to 0 to disable caching
 from django.conf.urls.defaults import *
 from django.http import HttpResponsePermanentRedirect
 from mango.feeds import atom
-from mango.settings import CONTACT_FORM, PATH_TO_STATIC
+from mango.settings import CONTACT_FORM, PATH_TO_STATIC, TAGS_PAGE
 from mango.views import archives, contact, index, post, redirect, tagged_as, tags
 
 urlpatterns = patterns('')
 		(r'^contact/(thanks/)?$', contact),
 	)
 
+if TAGS_PAGE:
+	urlpatterns += patterns('',
+		(r'^tags/$', tags),
+		(r'^tag/([^/]+)/$', tagged_as),
+	)
+
 urlpatterns += patterns('',
 	(r'^$', index),
 	(r'^feed/$', atom),
-	(r'^tags/$', tags),
-	(r'^tag/([^/]+)/$', tagged_as),
 	(r'^archive/$', lambda request: HttpResponsePermanentRedirect('/archives/')),
 	(r'^archives/$', archives),
 	(r'^(.+?)/redirect/$', redirect),