0
我使用Django web框架來開發我的網站。我的項目中的python文件如下Apache無法加載utf8 python文件
# -*- coding: utf-8 -*-
def index(request):
model = MyModel.objects.all()[0]
if model.name == 'é':
return HttpResponse("True")
else
return HttpResponse("False")
我'name'變量總是'é',但它返回false。
我使用Apache 2.2和Python 2.7.3通過mod_wsgi的加載我的web應用程序作爲this link