cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Basic Question

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 1 Feb 2002 09:11:45 +0100 (MET)

On Thu, 31 Jan 2002, Anurag Singh wrote:

> In the postit2.c example, I don't want the returned page printed to the
> standart output. Instead, I want to save it in a string. Does anyone know
> how to do it?

Yes, I believe I can. As a matter of fact, all people that have read the FAQ
should have a clue! ;-) Paragraph 5.2 "How can I receive all data into a
large memory chunk?" is what you want, scroll down a bit on:

        http://curl.haxx.se/docs/faq.shtml

There's also another example called "getinmemory.c" that shows how to do
this:

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

Of course, the by far most complete guide and tutorial on how to become a
succesful libcurl user is found here:

        http://curl.haxx.se/libcurl/c/the-guide.html

-- 
    Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/
Received on 2002-02-01