diff --git a/part2/helloworld/helloworld/settings.py b/part2/helloworld/helloworld/settings.py index f59ce44..8d5734b 100644 --- a/part2/helloworld/helloworld/settings.py +++ b/part2/helloworld/helloworld/settings.py @@ -20,11 +20,11 @@ SECRET_KEY = 'h#!izko_ejn@&0g@a#yu$tpuh-a=v$vvcfq5p*y#@2rzfcojn7' # SECURITY WARNING: don't run with debug turned on in production! -DEBUG = True +DEBUG = False TEMPLATE_DEBUG = True -ALLOWED_HOSTS = [] +ALLOWED_HOSTS = [u'gyt-mac.local'] # replace the content by your host name # Application definition diff --git a/part2/helloworld/helloworld/urls.py b/part2/helloworld/helloworld/urls.py index 4f2d668..2fef9aa 100644 --- a/part2/helloworld/helloworld/urls.py +++ b/part2/helloworld/helloworld/urls.py @@ -1,14 +1,15 @@ -from django.conf.urls import patterns, include, url +from django.conf.urls import include, url from django.contrib import admin +from helloworld import views -urlpatterns = patterns( - '', +urlpatterns = [ # Examples: # url(r'^$', 'helloworld.views.home', name='home'), # url(r'^blog/', include('blog.urls')), url(r'^admin/', include(admin.site.urls)), - (r'^hello', 'helloworld.views.index'), + url(r'^hello', views.index, name='index'), + +] -)