Jump to content
  • Advertisement
Sign in to follow this  
Huangdi

Fetching a web page with C++

This topic is 5141 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Advertisement
Please don't crosspost

Other then that, get yourself a general (non language specific) network tutorial first, then look up the commands specific to your prefered language. Next you need a tutorial on which commands you need to send to a webserver. And if you want to parse and display the html page get yourself a browser. Or be prepared for a real lot of work.

Share this post


Link to post
Share on other sites
Or if you are really lazy and run linux you can use system("wget ..."); // don't now the arguments for wget
To store the page in a temporary file, then open that file from C++

Share this post


Link to post
Share on other sites
Quote:
Original post by twanvl
Or if you are really lazy and run linux you can use system("wget ..."); // don't now the arguments for wget


example usage of wget:

panda@industry:~$ wget http://www.yahoo.com/
--12:40:58-- http://www.yahoo.com/
=> `index.html'
Resolving www.yahoo.com... done.
Connecting to www.yahoo.com[66.94.230.46]:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]

[ <=> ] 31,654 176.64K/s

12:40:58 (176.64 KB/s) - `index.html' saved [31654]


another usage:

panda@industry:~$ wget ftp://path_to_file/
etc etc etc

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!