C# 发送HTTP中文请求

2025-05-23 02:15:56
推荐回答(2个)
回答1:

HttpUtility.UrlEncode()转换一下
string url = HttpUtility.UrlEncode("http://localhost/a.aspx?aaa=中国");
string str = w.DownloadString(url);

记得要引用空间

回答2:

试试utf-8