Django的TEMPLATE_DIRS配置疑问
django 1.8 windows下的
TEMPLATE_DIRS = (
r'C:\Users\xin\Desktop\web_project\assets_yunwei\templates',
#'./templates',
#os.path.join(BASE_DIR,'templates'),
#os.path.join(os.path.dirname(__file__), 'templates').replace('\\','/'),
)
不生效,谁知道怎么回事呢?哪里不对,应该如何配置哦? 你可以使用最后一种,保证templates在app的目录下,就可以了 回复 2# huangxiaohen
非常感谢!{:yxh53:} 回复 1# chenxin6676 使用 / 而不是 \
页:
[1]