Page 1 of 1

Updates.php Broken?

Posted: Thu Dec 29, 2011 11:18 am
by joeserg
When attempting to get a list of series/episodes and even the server time (using type=none) I am receiving the following in my browser:
<?xml version="1.0" encoding="UTF-8" ?>
Logging your IP. Have a nice day!
The same is displayed using the sample update URL from the developer wiki. Is there a problem with the API or should I be using a newer method to update series data?

Re: Updates.php Broken?

Posted: Thu Dec 29, 2011 12:23 pm
by sabirmostofa
This is not a TvDb issue. Most probably you're using a WordPress Multisite and trying to access the file.

Re: Updates.php Broken?

Posted: Thu Dec 29, 2011 1:00 pm
by joeserg
No WordPress here I'm afraid. I have a cron job that executes a PHP script every hour. It retrieves a list of series and episodes that have changed in the last hour and updates my database accordingly. Until today I could load http://www.thetvdb.com/api/Updates.php?type=none and get the correct XML response. However, I now see the response that I've included in the original post.

Re: Updates.php Broken?

Posted: Thu Dec 29, 2011 3:16 pm
by b4s5
I'm having the same problem. For the past 5 hours http://www.thetvdb.com/api/Updates.php?type=none isn't loading. It keeps returning

Code: Select all

<?xml version="1.0" encoding="UTF-8" ?>
Logging your IP.  Have a nice day!
I have tried it in other browsers and from different ip-addresses with no success.

Re: Updates.php Broken?

Posted: Thu Dec 29, 2011 4:41 pm
by joeserg
b4s5 wrote:I'm having the same problem. For the past 5 hours http://www.thetvdb.com/api/Updates.php?type=none isn't loading.
I've fixed the problem. Unfortunately it means a different way of doing things. Reading through the Developer API Documentation a bit more thoroughly it appears that the Update.php method is now deprecated, which would explain why it has stopped working.

You now need to use the method outlined at http://thetvdb.com/wiki/index.php/API:Update_Records - which can still return an XML response, but for a minimum of 24 hours worth of updates. Each record in the XML response has a timestamp allocated, so it is possible to filter the results to a timeframe of your own (i.e. in my case only show records that have changed in the last hour).

The new XML file is accessed via http://thetvdb.com/api/[API_KEY]/updates/

Hope this helps. I've spent the last couple of hours updating my code to use this as the new source for updates.

Re: Updates.php Broken?

Posted: Thu Dec 29, 2011 5:10 pm
by hikaricore
Just so you know, there was an error on the site causing the "Have a nice day" message which should be resolved now.

Re: Updates.php Broken?

Posted: Thu Dec 29, 2011 5:25 pm
by joeserg
hikaricore wrote:Just so you know, there was an error on the site causing the "Have a nice day" message which should be resolved now.
I knew that would happen! Ah well, I guess it's better to be using the newer update method if the old one is deprecated?

Re: Updates.php Broken?

Posted: Fri Dec 30, 2011 8:56 am
by tack
I did precisely the same as you, joeserg. I'm also assuming it's better to continue on with the updates_(day|week|month).zip files, based on what the wiki says.