请大家帮忙看看,我的这段 代码有什么问题? String values2=new String(temp,"gb2312");试试 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 public String getStr(String str){ try { String temp_p =str; byte[] temp_t = temp_p.getBytes("ISO8859-1"); String temp = new String(temp_t); return temp; } catch(Exception e) { e.printStackTrace(); } return "null";} 写错了:byte[] temp=str.getBytes("ISO-8859-1"); 不用那么麻烦:<%request.setCharacterEncoding("gb2312");%> byte[] temp_t = temp_p.getBytes("ISO8859-1"); 谢谢,问题已经解决,ZFL_progress(兴软) 你的方法真的很好用!!谢谢!! 关与下载路径的问题,分不多了,忘高手指点谢谢 使用jpa做针对人员发短信碰到的问题,请大伙帮忙 jsp页面怎样分类显示 关于试用myeclipse7后遇到的问题.... 一个让我很头痛的下载问题.我快疯掉了,....大家帮我看看吧. 用mina传大文本出错;请求帮助 关于SpringIOC中的autowire 关于用servlet大家帮帮忙 大家帮我看一下,这段代码是否能够链上数据库呢? eclipse一个超奇怪的问题! java中共有多少runtime exception? 什么时候用assert?
{
try
{
String temp_p =str;
byte[] temp_t = temp_p.getBytes("ISO8859-1");
String temp = new String(temp_t);
return temp;
}
catch(Exception e)
{
e.printStackTrace();
}
return "null";}
<%request.setCharacterEncoding("gb2312");%>