Pages

Thursday 15 July 2010

Setting up Django

I am currently beggining to work with Django, I followed the tutorial but in the second part, when trying to run the admin/ page, I get the error:

name 'admin' is not defined

Later I noticed that the tutorial shows how the file urls.py should look like, and that there three lines uncommented:


from django.contrib import admin
admin.autodiscover()

(r'^admin/', include(admin.site.urls))


I was missing the first two lines.

No comments:

Post a Comment