楼主,看过来:http://community.csdn.net/Expert/topic/3530/3530812.xml?temp=.6263849

解决方案 »

  1.   

    我用的是
    <%@ page contentType="text/html; charset=GBK"%>
      

  2.   

    在get页面加入
    <%@page contentType="text/html; charset=gb2312"%>
    <%request.setCharacterEncoding("GB2312");%>
      

  3.   

    我加了,
    <%@page contentType="text/html; charset=gb2312"%>
    <%request.setCharacterEncoding("GB2312");%>
    不好使
      

  4.   

    有没有办法直接修改tomcat的配置文件
      

  5.   

    有没有办法直接修改tomcat的配置文件
    ====================================================================
    有办法!
    http://community.csdn.net/Expert/topic/3582/3582938.xml?temp=.2923853
      

  6.   

    我在tomcat5.0中<Connector acceptCount='100' connectionTimeout='20000' debug='0'
    disableUploadTimeout='true' enableLookups='false'
    maxSpareThreads='75' maxThreads='150' minSpareThreads='25'
    port='8080' redirectPort='8443' URIEncoding='GBK'/>
    而在 tomcat4.0中文就是乱吗(get提交的)为什么
      

  7.   


    public static String gbTo(String gbStr)
    {
    String str = null;
    try{
    str    = new String(gbStr.getBytes("GB2312"),"8859_1");
    }catch(Exception e){}
    return       str;
    }
    public static String toGb(String Str)
    {
    String str = null;
    try{
    str    = new String(Str.getBytes("8859_1"),"GB2312");
    }catch(Exception e){}
    return       str;
    }
      

  8.   

    <% @page pageEncoding=gb2312%>