From 48c2e73048be15c7d575293e0e5c69b93ab92398 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 21 Jul 2010 21:30:13 -0700 Subject: More patches as part of #1225. Change the 'core' modules to use the json::reply method to set the content type header and encode the response as a json object --- modules/rest/helpers/rest.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'modules/rest') diff --git a/modules/rest/helpers/rest.php b/modules/rest/helpers/rest.php index bcb12d58..644779da 100644 --- a/modules/rest/helpers/rest.php +++ b/modules/rest/helpers/rest.php @@ -35,8 +35,7 @@ class rest_Core { } print "
$html
"; } else { - header("Content-type: application/json"); - print json_encode($data); + json::reply($data); } } -- cgit v1.2.3