cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Problems with CURLFORM_FILE?

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 20 Oct 2006 12:50:32 +0200 (CEST)

On Fri, 20 Oct 2006, Urban Johansson wrote:

> curl_formadd(&opost, &olast, CURLFORM_FILE,
> "c:\test.jpg",CURLFORM_END);

This only sets the content of this part, not the name. I think you have to set
the name for the part for it to work. Did you check the return code from
curl_formadd()?

Compare with this (working) example:

   http://curl.haxx.se/lxr/source/docs/examples/multi-post.c

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2006-10-20