优化json不转义中文

修正transform加载路径
This commit is contained in:
huangdijia
2015-03-11 08:39:10 +08:00
parent 40db699dc4
commit ae2ac61cf4
3 changed files with 4 additions and 4 deletions

View File

@@ -110,7 +110,7 @@ abstract class Rest {
if(empty($data)) return '';
if('json' == $type) {
// 返回JSON数据格式到客户端 包含状态信息
$data = json_encode($data);
$data = json_encode($data, JSON_UNESCAPED_UNICODE);
}elseif('xml' == $type){
// 返回xml格式数据
$data = xml_encode($data);