文本正文 //java--->jsp username=new String(username.trim().getBytes("iso-8859-1"),"utf-8"); //jsp--->jsp <%=new String(request.getParameter("name").getBytes("ISO-8859-1"),"utf-8") %> //springMVC,@RequestMapping(java-->jsp) @RequestMapping(value="/up_user", produces = "application/json; charset=utf-8") //jsp--->servlet: resp.setContentType("text/html;charset=utf-8"); req.setCharacterEncoding("utf-8"); |