ajax 回传参数

JSONObject json = new JSONObject();
json.put("msg", msg);
json.put("success", count);
json.put("error", count2);
String jsonString=json.toJSONString();
response.getWriter().write(jsonString);

原文地址:https://www.cnblogs.com/xuehen/p/4463210.html