首页 > 其他 > 详细

get请求乱码解决

时间:2018-04-20 21:45:58      阅读:165      评论:0      收藏:0      [点我收藏+]

1、修改tomcat的配置文件

<ConnectorURIEncoding="utf-8" connectionTimeout="20000" port="8080" protocol="HTTP/1.1" redirectPort="8443"/>

2、后台代码处理

String userName = new String(request.getParamter("userName").getBytes("ISO8859-1"),"utf-8")

get请求乱码解决

原文:https://www.cnblogs.com/suhfj-825/p/8893401.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!