response.setCharacterEncoding(“UTF-8”);
告诉客户端用什么编码
response.setHeader(“content-type”, “text/html;charset=UTF-8”);
上面两句能合成一句为:response.setContentType(“text/html;charset=UTF-8”)
httpservlet中文乱码问题
猜你喜欢
转载自blog.csdn.net/weixin_44647098/article/details/106192323
今日推荐
周排行