|Subject:||Re: TIdMultiPartFormDataStream alternative?|
|Posted by:||Remy Lebeau (TeamB) (firstname.lastname@example.org)|
|Date:||Sun, 23 Jan 2005|
"Vaelek @ LifeIsHell" <val-ne…@lifeishell.org> wrote in message
> Okay, I need to post data as the content-type
You are using the wrong approach then.
> However, since I'm using TIdMultiPartFormDataStream Indy
> automatically changes the content type to multipart/form-data.
As well it should. "application/x-www-form-urlencoded" and
"multipart/form-data" handle data very differently.
TIdMultiPartFormDataStream is specifically designed for
> Is there a type that is not multi-part that I cannot seem to find?
Use a normal TStrings class to store your data, such as TStringList, and
then pass that to Post() instead of TIdMultiPartFormDataStream.
> I am needing the actual post data stream to be in the format of
> var=val&var=val&var=val like IE does.
You are using the same name for multiple values. Which version of Indy are
you actually using? If Indy 9, then TIdHTTP does not support multiple
values with the same name. They won't be encoded properly. This has been
corrected in Indy 10.
TIdMultiPartFormDataStream alternative? posted by Vaelek @ LifeIsHell on Sun, 23 Jan 2005