HttpPost

public static string HttpPost(string url, string postData, bool isPost = true)
        {
            string method = isPost ? "POST" : "GET";

            HttpHelper http = new HttpHelper();
            HttpItem item = new HttpItem()
            {
                URL = url,
                Method = method,
                ContentType = "application/x-www-form-urlencoded",
                Postdata = postData,
            };
            HttpResult result = http.GetHtml(item);
            return result.Html;
        }

  

posted @ 2017-10-10 16:06  会弹猫的吉他  阅读(183)  评论(0编辑  收藏  举报