python-Django表单1
修改app1的路由
在views.py里面增加函数
在项目目录下面增加templates文件夹,并在其下面添加name.html文件
在项目配置文件里面的TEMPLATES里面修改DIRS配置如下
运行服务器,访问http://127.0.0.1:8000/app1/get_name得到name.html
修改app1的路由
在views.py里面增加函数
在项目目录下面增加templates文件夹,并在其下面添加name.html文件
在项目配置文件里面的TEMPLATES里面修改DIRS配置如下
运行服务器,访问http://127.0.0.1:8000/app1/get_name得到name.html