cURL / Mailing Lists / curl-library / Single Mail


problem saving urlcode (string)

From: <>
Date: Thu, 14 Apr 2005 12:45:48 +0200

Hi, i am programming under linux a programm which loads a website with a xml structur.
when i am trying to save the xmlcode string i get an empty file (1 byte large).

here is my code for reading the string:
res = curl_easy_perform(curl);
xmldata = res; // xmldata is a c++ string

here is my code for saving:

void saveData() {
   ofstream fout("xmldata.xml", ofstream::out);
   if (!fout)
      cout << "error" << endl;

   fout << xmldata;
   fout << flush;

the xmldata string, i also print out on console and the code is there, but saving this string doesn't work.

does somebody know, how to make it work?
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail:
Received on 2005-04-14