]> git.sommitrealweird.co.uk Git - sommitrealweird.git/blobdiff - sommitrealweird/urls.py
New menu code and reorg of URLs
[sommitrealweird.git] / sommitrealweird / urls.py
index 75c6a6381975d5ee2462255332f2582bc2e4832c..3cdfc7f601f00018007fccaaefdc4cf6bc7aaf4d 100644 (file)
@@ -10,8 +10,7 @@ urlpatterns = patterns('',
     # Uncomment this for admin:
     (r'^$', 'content.views.document_view', {'slug': 'index'}),
     (r'^admin/', include('django.contrib.admin.urls')),
-    (r'^content/(?P<slug>[^/]+)/$', 'content.views.document_view'),
-    (r'^content/(?P<folders>.*)/(?P<slug>[^/]+)/$', 'content.views.document_view'),
-    (r'^content/$', 'content.views.document_view', {'slug': 'index'}),
+    (r'^(?:content/|)(?P<slug>[^/]+)/$', 'content.views.document_view'),
+    (r'^(?:content/|)(?P<folders>.*)/(?P<slug>[^/]+)/$', 'content.views.document_view'),
     (r'^media/(?P<path>.*)$', 'django.views.static.serve', {'document_root': MEDIA_ROOT, 'show_indexes': True}),
 )