We're a community of 1076K IT Pros here for help, advice, solutions, professional growth and fun. Join us!
1,075,659 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Start New Discussion Reply to this Discussion

read web page by c++

Hi ,
I try to build mobile application , this application will know the book name you want and tell you price and Customer Reviews evaluation from amzon.com
but the problem I can not read web page to get price and Customer Reviews evaluation from it by c++ code ,
I try URLDownloadToFile but that mean I should download the page ...
so any solution ???

4
Contributors
3
Replies
1 Day
Discussion Span
7 Months Ago
Last Updated
5
Views
nada_fateha
Newbie Poster
1 post since Sep 2012
Reputation Points: 0
Solved Threads: 0
Skill Endorsements: 0

If I remember correctly, Amazon has an API you can use to retrieve product information. Check their website.

pritaeas
Posting Prodigy
Moderator
9,265 posts since Jul 2006
Reputation Points: 1,173
Solved Threads: 1,456
Skill Endorsements: 86

See this cURL library.

A simple cURL implementation code

#include <stdio.h>
#include <curl/curl.h>

int main(void)
{
   CURL *curl;
   CURLcode res;

   curl = curl_easy_init();
   if(curl) 
   {
     curl_easy_setopt(curl, CURLOPT_URL, "www.daniweb.com");
     res = curl_easy_perform(curl);
     curl_easy_cleanup(curl);
   }

   return 0;
 }

You will find this in their example codes.

Better try C# or java for web application purposes. but they also have their downside. See this.

np complete
Posting Whiz
385 posts since Sep 2010
Reputation Points: 18
Solved Threads: 36
Skill Endorsements: 0
Stefano Mtangoo
Senior Poster
3,731 posts since Jun 2007
Reputation Points: 462
Solved Threads: 396
Skill Endorsements: 0

This article has been dead for over three months: Start a new discussion instead

Post: Markdown Syntax: Formatting Help
 
You
View similar articles that have also been tagged:
 
© 2013 DaniWeb® LLC
Page rendered in 0.0724 seconds using 2.67MB