String tmpsubject = tmpjo.getString("title"); reqVo.setTitle(new String(tmpsubject.getBytes("utf-8"),"utf-8")); 本机测试编码没有问题,但是上线部署这里的编码就出问题了,应该怎么解决?求大神解答
收起
Tomcat 服务器是否配置 URIEncoding 了:
<Connector port="80" protocol="HTTP/1.1" connectionTimeout="8000" redirectPort="8443" useBodyEncodingForURI="true" URIEncoding="UTF-8" allowTrace="true"/>
报告相同问题?