summaryrefslogtreecommitdiffstats
path: root/web/lib/aurjson.class.php
diff options
context:
space:
mode:
authorChris Down <chris@chrisdown.name>2013-09-01 16:36:51 +0200
committerLukas Fleischer <archlinux@cryptocrack.de>2013-09-02 00:29:58 +0200
commit35c5a5a3a99277e6651fbc12392dd15aa7530002 (patch)
tree0b870d87efb30e1be44c43527c8e7d74ad1206ba /web/lib/aurjson.class.php
parentd225366f31aae250981f9f5bf8e43e633c631c73 (diff)
downloadaurweb-35c5a5a3a99277e6651fbc12392dd15aa7530002.tar.xz
Specify charset in Content-Type header when returning JSON data from API.
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'web/lib/aurjson.class.php')
-rw-r--r--web/lib/aurjson.class.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/web/lib/aurjson.class.php b/web/lib/aurjson.class.php
index b905275..4364e5d 100644
--- a/web/lib/aurjson.class.php
+++ b/web/lib/aurjson.class.php
@@ -43,6 +43,7 @@ class AurJSON {
// overwrite cache-control header set in aur.inc to allow caching, but
// require validation
header('Cache-Control: public, must-revalidate, max-age=0');
+ header('Content-Type: application/json, charset=utf-8');
// handle error states
if ( !isset($http_data['type']) || !isset($http_data['arg']) ) {