cURL / Mailing Lists / curl-library / Single Mail

curl-library

No output in an http get request

From: Alejandro Ramiro Ruiz <a_ramiro8_at_hotmail.com>
Date: Tue, 03 Jan 2006 13:48:45 +0000

Hi to all,

I have a C++ program that must do an HTTP GET request. When I execute my
example, all the html code of the requested URL is shown by th standar
output and the standar error. I've adapted a code that I found and I think
that these two lines are the responsible for this:

            // (sending response headers to stderr)
         curl_easy_setopt( ctx , CURLOPT_WRITEHEADER , stderr ) ;

        // response content: same choices as headers
        // send it to stdout to prove that libcURL differentiates the two
         curl_easy_setopt( ctx , CURLOPT_WRITEDATA , stdout ) ;

but I don't know how to execute this in a way that no output at all could be
shown. I get the information I need by the curl_easy_getinfo() method so, I
need no output. I would like to make the request in absolute silent. Someone
can help me please?.

Thanks a lot. Sorry for my English, I hope I had been able to make myself
understood.

Alejandro Ramiro.
Received on 2006-01-03