#代表你的根URLconf的模組名
ROOT_URLCONF = 'testweb.urls'
TEMPLATES = [
{
#要使用的模組名稱模板後端,內置的模板後端如下,还有django.template.backends.jinja2・Jinja2,
'BACKEND': 'django.template.backends.django.DjangoTemplates',
#在捜索顺序中引擎应该寻找模板源文件的目錄,即绝对路径html 路徑
'DIRS': [],
#设置引擎是否应该在安装的应用程序中
'APP_DIRS': True,
#额外的参数传递给模板后端,可用参数因模板后端而不同
'OPTIONS': {
'context_processors': [
'django.template.context_processors.debug',
'django.template.context_processors.request',
'django.contrib.auth.context_processors.auth',
'django.contrib.messages.context_processors.messages',
],
},
},
]