3
Contributors
3
Replies
5
Views
7 Years
Discussion Span
Last Post by ralphc++
0

Hello there,
What would be a simple way to stream a file from a url?

I figured it out.. Im using libcURL\

#include <curl/curl.h>

  CURL *curl;
  CURLcode results;
 
  curl = curl_easy_init();
  if(curl) {
    curl_easy_setopt(curl, CURLOPT_URL, "curl.haxx.se");
    results = curl_easy_perform(curl);
    cout<<"results: "<<sizeof(results)<<" "<<results<<endl;
    /* always cleanup */ 
    curl_easy_cleanup(curl);
  }

to include the right libs when linking type:

$curl-config --libs
-lcurl -lidn -llber -lldap -lrt -lgssapi_krb5 -lgssapi_krb5 -lz -lgnutls
$

and it will display all the needed libs

0

Hey,

I read your post about using the curl library. Can you help me figure out what you meant when you wrote,

to include the right libs when linking type:

$curl-config --libs
-lcurl -lidn -llber -lldap -lrt -lgssapi_krb5 -lgssapi_krb5 -lz -lgnutls
$

and it will display all the needed libs

I am using VC++ 6.0 in XP. I am hoping to use the curl library to open 100000 http pages and save the results. Any help is appreciated.

0

Hi,
if there is a free solution, can someone put up a zip with the needed libs and a working example to do over modifies? Would be a great help to us!

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.