String strs = request.getParameter("yourstrs");
byte b[] = strs.getBytes("ISO-8859-1");
strs = new String(b);
简洁写法:
String convert = new String(request.getParmater("inputname").trim().getBytes("ISO8859_1"), "GBK");
posted on 2006-11-10 09:53
崛起的程序员 阅读(239)
评论(0) 编辑 收藏