Added ability to host website not at the root, eg. http://m.com/troggle/

This commit is contained in:
Martin Green
2011-05-02 02:37:33 +01:00
parent b439d40120
commit cdf54e0f9b
4 changed files with 14 additions and 5 deletions

View File

@@ -15,7 +15,7 @@ admin.autodiscover()
# type url probably means it's used.
urlpatterns = patterns('',
actualurlpatterns = patterns('',
url(r'^$', views_other.frontpage, name="frontpage"),
url(r'^todo/$', views_other.todo, name="todo"),
@@ -128,3 +128,8 @@ urlpatterns = patterns('',
#url(r'^trip_report/?$',views_other.tripreport,name="trip_report")
)
#Allow prefix to all urls
urlpatterns = patterns ('',
('^%s' % settings.DIR_ROOT, include(actualurlpatterns))
)