Exemplo n.º 1
0
        public Task <WebElement> PostToUrlAsync(Uri url, NameValueCollection parameters)
        {
            var result = Task.Factory.StartNew(() =>
            {
                var htmlArray = _webClient.UploadValues(url, "POST", parameters);
                var html      = _browser.HtmlEncoding.GetString(htmlArray);
                return(ParseDocument(html, url));
            });

            return(result);
        }
        public string ExternalPostToUrl(Uri url, NameValueCollection parameters)
        {
            var htmlArray = _webClient.UploadValues(url, "POST", parameters);

            return(_browser.HtmlEncoding.GetString(htmlArray));
        }