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")