urls.py
changeset 5 7358eeae14d8
parent 2 8d8ada9849be
child 6 4e819dd96e1f
equal deleted inserted replaced
4:22e66e1ed995 5:7358eeae14d8
     1 from django.conf.urls.defaults import *
     1 from django.conf.urls.defaults import *
       
     2 from django.conf import settings
       
     3 from django.views.generic.simple import direct_to_template
       
     4 
       
     5 import os.path
     2 
     6 
     3 # Uncomment the next two lines to enable the admin:
     7 # Uncomment the next two lines to enable the admin:
     4 # from django.contrib import admin
     8 # from django.contrib import admin
     5 # admin.autodiscover()
     9 # admin.autodiscover()
     6 
    10 
    12     # to INSTALLED_APPS to enable admin documentation:
    16     # to INSTALLED_APPS to enable admin documentation:
    13     # (r'^admin/doc/', include('django.contrib.admindocs.urls')),
    17     # (r'^admin/doc/', include('django.contrib.admindocs.urls')),
    14 
    18 
    15     # Uncomment the next line to enable the admin:
    19     # Uncomment the next line to enable the admin:
    16     # (r'^admin/', include(admin.site.urls)),
    20     # (r'^admin/', include(admin.site.urls)),
       
    21     url (r'^$', direct_to_template, {"template": "homepage.html"}, name="home"),
       
    22     (r'^register/','content.views.register'),
       
    23     (r'^logout/','content.views.logout'),
       
    24     (r'^regthank/(?P<id>\d+)/$', 'content.views.regthank'),
       
    25     (r'^site_media/(?P<path>.*)$', 'django.views.static.serve', {'document_root': 'site-content'}),
    17 )
    26 )