js里替换一下返回值: newData=data.replace(/\s/g,'');
上篇:jquery/ajax:ajax传递json数组字符串到后台(JSON.stringify)
下篇:ajax:php返回带换行的加送数据处理