摘要:
一、获取输入的中文 1、post方式设置request编码方式 request.setCharacterEncoding("UTF-8"); 其中“UTF-8”根据提交请求的页面编码而定,即提交请求的页面编码是什么,这里就是什么。 2、Get方式 当请求以GET方式提交时,设置request编码无效。因为Get方式提交请求时,其编码方式固定为“ISO8859-1” 正确做法是: String param = request.getParameter("name"); String cParam = new String(para... 阅读全文
posted @ 2014-04-09 16:17 孤骊 阅读(458) 评论(0) 推荐(0)
浙公网安备 33010602011771号