cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: File transfer using http post

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 2 Mar 2007 22:17:50 +0100 (CET)

On Fri, 2 Mar 2007, madhusudhan.nanjappa_at_wipro.com wrote:

> I was using CURLOPT_INFILESIZE_LARGE. But that was not working either. The
> Content-Length field was shown as 0.

Then I would guess you have a mismatch between your app and libcurl on how big
they consider the curl_off_t type is. But you can just as well use the
CURLOPT_INFILESIZE with a long as long as your posted data is less than the
amount a long can hold.

> And the server was showing an incoming connection as
> application/x-www-form-urlencoded. Should'nt it be of multipart/form-data
> type?

No, then you should use the CURLOPT_HTTPPOST option.

-- 
  Daniel
Received on 2007-03-02