数据库为mysql 4.0 用的mysql control centerjsp页面中,只有显示数据库中数据的汉字显示为"??" 其他汉字正常.
解决方案 »
- 从本质上讨论Struts2获取request的方法
- 弱弱的问一句~ 大家有多久没有看java的API了
- 如何获取动态添加的File控件的文件路径?
- 用struts提交的表单数据是乱码怎么办
- jsp中while(rs.next())问题
- netbeans怎样编译javabean
- 关于persistence.xml问题,急!!!!!!!!!!!!!!!
- 寻JSP群与JSP高手
- tomcat 4.1.18 与 sun one studio 集成
- 关于freemaker 导出word文档中list嵌套循环问题
- jsp下如得到打开新页面里的值
- jsp中调用javabean是线程安全的吗,有那几个方面的问题
struts结构
在struts-config.xml文件中的. <set-property property="url"
value="jdbc:mysql://localhost:3306/test?useUnicode=true&characterEncoding=GBK" />在eclipse下用run就能通过.在IE下就是不行.
fatal erorr
The reference to entity"characterEncoding" must end with ";" delimiter..
这是什么错误?????
<set-property property="url"
value="jdbc:mysql://localhost:3306/test?useUnicode=true&characterEncoding=GBK" />
这一句好是出问题.如果不出问题.那么显示就是正常的了.
jdbc:mysql://localhost:3306/test?useUnicode=true&characterEncoding=GBK
这句url在eclpse下就没问题.
在tomcat下就有问题.
错误是说你少写了个;
你的乱码要加转换的
getbutton=new String(getbutton.getBytes("ISO8859_1"), "gb2312");
{
try{
String w_b=new String(en.getBytes("ISO8859_1"),"GBK"); if (en.length()>w_b.length())
en=w_b;
}catch(Exception e){}
return en;
}