Re: How to change Content-Type & boundary?
Date: Fri, 14 Sep 2007 12:56:32 +0200 (CEST)
On Fri, 14 Sep 2007, 时有 wrote:
> I have some problem with change the Conten-Type & boundary,please help: I
> changed content-type in the header: Content-Type:
libcurl doesn't really support this operation. If you're not happy with
libcurl's multipart formpost as done built-in, you're better off:
1) using a normal POST and then handicraft the rest yourself in your
2) work on a patch that allows an application to alter the necessary pieces
> Content-Type: multipart/form-data; boundary=--------------------
The actual "multipart/form-data" part is meant to be able to change by setting
Content-Type to something (see lib/http.c:1957) but I'm not 100% sure it
works... When doing a multipart post, the provided content-type content only
replaces the built-in type and not the boundary part following it.
-- Commercial curl and libcurl Technical Support: http://haxx.se/curl.htmlReceived on 2007-09-14