FormPostAdd & Request:Body - WeOnlyDo Discussion board

FormPostAdd & Request:Body (General questions)

by Skc, Saturday, September 22, 2007, 01:36 (6272 days ago)

FormPost.Add allows me to format data to be sent to the server for update. I was able to use it successfully. However if I tried to set my own string and set it directly into Request.Body, it does not work.

Example (using the help sample)

(A) Successful
wodHttp1.Request.FormPost.Add Username , joe
wodHttp1.Request.FormPost.Add Password , joe
wodHttp1.Post http://www.weonlydo.com/HttpDLX/Demo/TestFormPost.asp

(B) Failed
wodHttp1.Hostname = www.weonlydo.com
wodHttp1.Request.Body = Username=joe&Password=joe
wodHttp1.Post /HttpDLX/Demo/TestFormPost.asp

Why is it that setting data direct into Request.Body does not work? Or Request.Body is not meant to be used in this way?

Thanks for any answer.


Complete thread: