libcurl get JSON string -


i'm sorry simple question i'm new using libcurl. have following code:

    curl_easy_setopt(curl, curlopt_url, "http://mypage.com/index.php?datasourceid=1");      curl_easy_setopt(curl, curlopt_httpget, 1);      res = curl_easy_perform(curl); 

everything works fine, when curl_easy_perform(curl) executed json string in console , want string in variable.

please can me ?

any suggestion appreciated.

you need ask libcurl write directly own memory buffer via curlopt_writedata option.

please refer getinmemory example precisely illustrates how that.


Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -