0

How can i parse with PHP this Amazon product page and retrieve the product description?

<div class="bucket">
    <h2>Descrizione del prodotto</h2>
    <div class="content">Taglia la corda per dare i bonbon al mostriciattolo ...</div>
</div>

I need text into div with class "content", but there are more than one div with class "bucket" and "content" in this page.

Vasco Romano
  • 11
  • 1
  • 1

1 Answers1

4

Just sign up as an associate, and you get access to the api... Much easier than parsing HTML

https://associates.amazon.ca/gp/advertising/api/detail/main.html

and heres a handy PHP wrapper, for working with the API

http://www.binpress.com/app/amazon-product-advertising-api-php-wrapper/831

And a tutorial for how to do it...kinda...

http://www.codediesel.com/php/accessing-amazon-product-advertising-api-in-php/

It is confusing at first, with the ACCESS KEY and ASSOCIATE TAG and what not, but once you get it working and you learn it, its a very very useful skill to have.

Many many clients want to integrate amazon into their sites, so learning this skill is really priceless :)

Kylie
  • 11,421
  • 11
  • 47
  • 78