Django中的ROOT_URLCONF错误

Django中的ROOT_URLCONF错误,django,Django,我的URL.py中有以下内容: ROOT_URLCONF = 'sdaps_web.urls' 访问url localhost:port时,我收到以下错误: 'AdminSite' object has no attribute 'root' URL配置: url(r'^admin/(.*)', include(admin.site.urls)), url(r'^', include(views)), url(r'^', include(sdaps_ctl.views)), url(r'^a

我的URL.py中有以下内容:

ROOT_URLCONF = 'sdaps_web.urls'
访问url localhost:port时,我收到以下错误:

'AdminSite' object has no attribute 'root'
URL配置:

url(r'^admin/(.*)', include(admin.site.urls)),
url(r'^', include(views)),
url(r'^', include(sdaps_ctl.views)),
url(r'^admin/(.*)', admin.site.root),
url(r'^accounts/', include('registration.urls')),
url(r'^$', direct_to_template,
        { 'template': 'index.html' }, 'index'),

我正在运行Django 1.6.1。。。有什么想法吗?

应该是
admin.site.url
,而不是
admin.site.root

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

现在我在/accounts/login/at异常值处获得TemplateDoesNotExist:registration/login.html
django registration
没有任何模板。你必须自己写,我有。只是不知道放在哪里。在
模板
目录中创建
注册
目录(与您的
index.html
一起),然后将
登录.html
模板放在这个
模板/注册
目录中。我已经将该文件放在目录中,仍然错误:"root@mmm:/opt/webapp/sdaps/sdaps_web/templates/registration#ls login.html“