javascript 处理返回json中的\u中文乱码问题(也不是乱码了,就是\u编码)

[ 2015-02-04 10:53:25 | 作者: admin ]
字号: | |


    function unicode2Chr(str) {
                     return unescape(str.replace(/\\/g, "%"))
                     }



例如输入:{"status":"error","message":"\u53c2\u6570\u9519\u8bef"}

返回:{"status":"error","message":"参数错误"}
评论Feed 评论Feed: http://blog.xg98.com/feed.asp?q=comment&id=2260

这篇日志没有评论。

此日志不可发表评论。