From: neil on
Hi, I would like to build a program in C++ that (basically) retrieves
data from several websites and then displays the data in a particular
way.
I need some advice as to which functions / classes in the Standard
Library that might be suitable for this purpose.
So far, it has been suggested that the only way I could do this would be
by use of a third party library, that's written in C, namely Libcurl.
Is this sound advice or is there a 'pure' C++ way of doing this? (I'm
using unix system).
Thanks
From: Francesco S. Carta on
neil <invalid(a)invalid.net>, on 07/08/2010 19:02:07, wrote:

> Hi, I would like to build a program in C++ that (basically) retrieves
> data from several websites and then displays the data in a particular
> way.
> I need some advice as to which functions / classes in the Standard
> Library that might be suitable for this purpose.
> So far, it has been suggested that the only way I could do this would be
> by use of a third party library, that's written in C, namely Libcurl.
> Is this sound advice or is there a 'pure' C++ way of doing this? (I'm
> using unix system).
> Thanks

No "direct" way to do that in C++, have a look at boost::asio

--
FSC - http://userscripts.org/scripts/show/59948
http://fscode.altervista.org - http://sardinias.com
From: Stefan van Kessel on
The C++ standard says nothing about networking. How networking is
handled is OS specific. In *nix you can look for the POSIX functions or
use a library like libcurl, which you mentioned or boost::asio which is
a OS independent C++ networking library. Libcurl also takes care of
Application Layer protocols whereas if you use boost::asio or POSIX
functions you have to implement that yourself. Simply fetching some
resources via http is reasonably straight forward though.

Have a nice day,
Stefan

On 8/7/2010 9:02 PM, neil wrote:
> Hi, I would like to build a program in C++ that (basically) retrieves
> data from several websites and then displays the data in a particular
> way.
> I need some advice as to which functions / classes in the Standard
> Library that might be suitable for this purpose.
> So far, it has been suggested that the only way I could do this would be
> by use of a third party library, that's written in C, namely Libcurl.
> Is this sound advice or is there a 'pure' C++ way of doing this? (I'm
> using unix system).
> Thanks

From: Ian Collins on
On 08/ 8/10 07:02 AM, neil wrote:
> Hi, I would like to build a program in C++ that (basically) retrieves
> data from several websites and then displays the data in a particular
> way.
> I need some advice as to which functions / classes in the Standard
> Library that might be suitable for this purpose.
> So far, it has been suggested that the only way I could do this would be
> by use of a third party library, that's written in C, namely Libcurl.
> Is this sound advice or is there a 'pure' C++ way of doing this? (I'm
> using unix system).

It is sound advice, libcurl is the best tool for the job.

--
Ian Collins