HTTP form encoding

  • Thread starter Thread starter D2
  • Start date Start date
D

D2

Hi,

In my http client application I need to submit a form programmatically
using HttpWebRequest class. I understand that the field data need to
be encoded before sending to the web server. Is there a built-in class
in .net that could help me encode data before sending?

Cheers!
D2
 
D2 said:
In my http client application I need to submit a form programmatically
using HttpWebRequest class. I understand that the field data need to
be encoded before sending to the web server. Is there a built-in class
in .net that could help me encode data before sending?

System.Web.HttpUtitility has methods UrlEncode and UrlDecode.
 
* D2 wrote, On 28-6-2007 17:50:
Hi,

In my http client application I need to submit a form programmatically
using HttpWebRequest class. I understand that the field data need to
be encoded before sending to the web server. Is there a built-in class
in .net that could help me encode data before sending?

Cheers!
D2

Microsoft has also released a safer, better and improved version of this
library which is less susceptible to Cross Site Scripting.

You can find it here:

http://www.microsoft.com/downloads/...92-7ad9-496c-9a89-af08de2e5982&displaylang=en

Jesse
 
Back
Top