乱码处理

请求参数乱码(中文乱码)

new String(username.getBytes("ISO-8859-1"),"UTF-8")
post表单提交到servlet action路径写法
<url-pattern>/helloform</url-pattern>
<form  action="helloform"  method="POST">   去掉“/”
posted @ 2018-05-12 14:47  chenhonggao  阅读(132)  评论(0编辑  收藏  举报