一、官方的约定:
1、在django中有一个约定、那就是每一个app自己的模板最好放在自己app目录下的templates子目录下、
但是这个还没有完成、最好还是在templates目录下加一个app同名的字目录、然后模板就放在这个子目录下。
二、创建使用模板的视图:
三、配置url映射:
四、index.html模板的详细内容:
五、detail模板是详细内容:
六、查看页面的效果:
index页面代码:
七、查看detail页面效果:
detail页面源码
----