Quote:
Originally Posted by Jordan
Good deal! How did you figure it out, trial and error?
|
It was partly trial and error and partly random luck!
While looking for something different, I found someone on a forum having a similar problem trying to scrape some content from another site and needing to spoof their user agent before the server would like them. I wondered if my problem was the same and it looks like it was.
Here is the finished, working version of the
comics page. It pulls the latest comic from both Dilbert and xkcd, caching them every hour on my server.
I might make this into a tutorial, if it continues to work for the next few days without showing any more problems! It's a nice simple example of cURL and degradable ajax.