summaryrefslogtreecommitdiff
path: root/program
diff options
context:
space:
mode:
authorErnesto Rico-Schmidt <e.rico.schmidt@gmail.com>2014-03-12 09:58:05 (GMT)
committerErnesto Rico-Schmidt <e.rico.schmidt@gmail.com>2014-03-12 09:58:05 (GMT)
commit395795e9aa00a922b4839019ca9e28438d0b3985 (patch)
treea69e97b3b40120dfe7f43807f46d5a9e1c7ab1e0 /program
parenta1e6deb0bf70944a70111c41438456abe2f867e3 (diff)
forced json output to utf-8
Diffstat (limited to 'program')
-rw-r--r--program/views.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/program/views.py b/program/views.py
index 49bcd57..bc7700e 100644
--- a/program/views.py
+++ b/program/views.py
@@ -146,7 +146,7 @@ def json_day_schedule(request, year=None, month=None, day=None):
else:
schedule.append((ts.start.strftime('%H:%M:%S'), ts.programslot.show.name, -1))
- return HttpResponse(json.dumps(schedule), content_type="application/json; charset=utf-8")
+ return HttpResponse(json.dumps(schedule, ensure_ascii=False, encoding='utf8').encode('utf8'), content_type="application/json; charset=utf-8")
def tofirstdayinisoweek(year, week):
# http://stackoverflow.com/questions/5882405/get-date-from-iso-week-number-in-python