2👍
✅
The documentation suggests placing your template directories in TEMPLATES DIRS
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [
BASE_DIR + '/templates/'
],
'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',
],
},
},]
You should also use os.path.join(BASE_DIR, 'templates')
to get your template path.
https://docs.djangoproject.com/en/1.11/ref/settings/#std:setting-TEMPLATES
Source:stackexchange.com