![](https://img-blog.csdnimg.cn/20201014180756930.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Python-Django
--沙子--
这个作者很懒,什么都没留下…
展开
-
Django-hello world
1、创建项目 2、创建应用 3、运行python manage.py runserver运行服务器 4、创建视图函数view.py from django.http import HttpResponse def home(request): return HttpResponse("hello world") 5、视图函数对应的URL: urlpatter原创 2016-03-04 11:25:29 · 187 阅读 · 0 评论 -
Django-UnicodeDecodeError at /test 'utf8' codec can't decode byte 0xb9 in position 38: invalid star
错误: UnicodeDecodeError at /test 'utf8' codec can't decode byte 0xb9 in position 38: invalid start byte 写了一个html文件,一直运行不成功。 原因:html保存自动默认的编码是GBK,应该该改为utf-8,具体作做法如下: 1、右击test.html,选择properities,把默认原创 2016-03-04 17:15:20 · 649 阅读 · 0 评论