Java HttpServletRequest乱码问题
方法一:
request.setCharacterEncoding("utf-8");
String user=request.getParameter("user");
方法二:
String user=new String(request.getParameter("user").getBytes("iso-8859-1"),"utf-8");
方法一:
request.setCharacterEncoding("utf-8");
String user=request.getParameter("user");
方法二:
String user=new String(request.getParameter("user").getBytes("iso-8859-1"),"utf-8");