中文应该使用GB2312的编码System.Text.Encoding.GetEncode("GB2312");

解决方案 »

  1.   

    我的意思:
    有个string postData有中文,
    UTF8Encoding  encoding=new UTF8Encoding();
    byte[]  byte1=encoding.GetBytes(postData);
    byte写入stream,然后stream传入HttpWebRequest,
    发现问题:中文有问题!如果全是英文就没有。
      

  2.   

    string postData="SearchType=1&zone=徐汇区&pubtype=1&rooms=2&halls=1&RentPrice1=1000&RentPrice2=5000&FitState=&days=1&keyword=&imageField2.x=5&imageField2.y=10";把  徐汇区&pubtype=1 看做为一个参数了 ,晕! 所以少了pubtype这个参数!
      

  3.   

    UTF8Encoding  encoding=new UTF8Encoding();这个改一下别的编码阿