摘要:
在Eclipse中直接Run得到的结果不是乱码(UTF-8编码)而在Eclipse中使用Maven tomcat:run发现结果是乱码通过new String(temp.toString().getBytes(可能的编码), "utf-8")的方式测试 知道乱码是因为采用了GBK编码但项目工程设置的Text file encoding为UTF-8 为什么是GBK呢?通过下面的代码知道在tomcat容器中file.encoding的编码仍然是GBK,所以修改Eclipse->Windows->Preferences->Workspace->Text f 阅读全文
posted @ 2013-01-09 13:59
return null;
阅读(459)
评论(0)
推荐(0)
浙公网安备 33010602011771号