ServletOutputStream outputStream = response.getOutputStream();
response.setContentType(“application/json;charset=utf-8”);
outputStream.write(json.getBytes(StandardCharsets.UTF_8));
一个错误!!响应格式不能忘!!! 解决json中文乱码
最新推荐文章于 2024-07-24 08:38:45 发布
ServletOutputStream outputStream = response.getOutputStream();
response.setContentType(“application/json;charset=utf-8”);
outputStream.write(json.getBytes(StandardCharsets.UTF_8));