参考:http://www.jb51.net/article/22437.htm

1、在web.config里配制<globalization requestEncoding="gb2312" responseEncoding="gb2312" />

2、做URL的时候进行编码,然后再解码

编码:

id = HttpUtility.UrlEncode(id, System.Text.Encoding.GetEncoding("GB2312"));

解码:

id = HttpUtility.UrlDecode(id, System.Text.Encoding.GetEncoding("GB2312"));

相关文章:

  • 2021-03-30
  • 2021-09-18
  • 2021-12-05
  • 2022-02-08
  • 2021-06-07
  • 2021-12-18
  • 2022-02-25
猜你喜欢
  • 2021-06-29
  • 2021-09-20
  • 2021-11-13
  • 2021-07-02
  • 2022-12-23
  • 2021-12-29
相关资源
相似解决方案