cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-library Mailing List Archives

Re: Writing response to a buffer

From: Ralph Mitchell <ralphmitchell_at_gmail.com>
Date: Thu, 3 Aug 2006 01:13:06 -0500

Take a peek at:

http://curl.haxx.se/lxr/source/docs/examples/getinmemory.c

It shows how to use the callbacks to get the returned data into a memory buffer.

Ralph Mitchell

On 8/3/06, Teresa Thomas <tere.ertw_at_gmail.com> wrote:
> Currently I am using the following code to obtain the HTTP responses into
> files:
>
> /* we want the headers and body to this file handle */
> curl_easy_setopt(curl_handle, CURLOPT_WRITEHEADER ,headerfile);
> curl_easy_setopt(curl_handle, CURLOPT_WRITEDATA ,bodyfile);
>
> where headerfile and bodyfile are of type FILE*
>
> How can I redirect the (mainly the body) response to strings/character
> buffers?
>
> Thanks!
>
Received on 2006-08-03

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET