📜  C# HttpClient POST 请求 - C# 代码示例

📅  最后修改于: 2022-03-11 14:49:00.435000             🧑  作者: Mango

代码示例2
string URI = "http://www.myurl.com/post.php";
string myParameters = "param1=value1¶m2=value2¶m3=value3";

using (WebClient wc = new WebClient())
{
    wc.Headers[HttpRequestHeader.ContentType] = "application/x-www-form-urlencoded";
    string HtmlResult = wc.UploadString(URI, myParameters);
}