Use PHP to connect (fairly easily) to Amazon's XML feed

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

I downloaded the SDK for Amazon's Associate program.  Hmmm... not so good.

Then, after a few hours of frustration, I found this page at SitePoint:

I had to install a bunch of PEAR packages, but the process was fairly

I used `curl` to place the output of the PHP script into my .shtml pages.

I also created a variant of their code which accepts command line
arguments.  It creates an HTML page full of Amazon books that match
keywords specified on the command line.  I redirect the output of that
command into a text file and then read that text file into my normal
.shtml template.

I also had to improve the code where they generate the URL to better
handle spaces.


Site Timeline