|
The HTTP Request is a component from the Clever Internet .NET Suite library. It allows you to create request data to be sent to the server with the POST or GET HTTP methods.
Use this component together with HTTP Client for submitting created request data to a web server for processing by a CGI, ASP.NET or Java servlet.
- 100% managed code
- Submit Form Values
- Submit File requests using .NET stream or file on the disk
- Multipart Form data, Text, XML and Binary data
- Parameter management - add/remove CGI name/value parameters to a HTTP request
- Define most common HTTP headers such as Range, Accept, Content-Type and any custom headers
- Can be used with any third party HTTP client
The HttpRequest component allows easy creation of request data in any formats including "multipart/form-data", "application/www-form-urlencoded", "text/xml" or any custom format.
You can add each form value manually as well as extract and create them from existing HTML source, URL or HTML page with FORM controls saved to the file.
string html = "<form action=' http://www.domain.com/submit.asp ' method='post'>" html += "<input type='text' name='username' value='John'>"; html += "<input type='file' name='userfile'>"; html += "<input type='submit' name='submit' value='submit'> </form>"; httpRequest1.BuildFormPostRequest(html); httpClient.Post("http://www.domain.com/submit.asp", httpRequest1, response); |
httpRequest1.Items.AddFormField("username", " John"); httpRequest1.Items.AddSubmitFile("userfile", "c:\\file.zip"); httpClient.Post("http://www.domain.com/submit.asp", httpRequest1, response); |
With HttpRequest you can create Form Post or Submit File requests without writing a single line of the code.
Simple put the component on to the form and choose the desired component menu: "Build by Url", "Build by File" or "Build by Text". After that the HttpRequest component will create all necessary request data and automatically change the HTTP header values.
Please see the Demos code (FormPost, SubmitFile) and also the indexed Help documentation provided with the Clever Internet .NET Suite installation to learn more about using this component in your application.
When Purchasing the Clever Internet .NET Suite you receive the full sources for all suite components and also free unlimited support.
|