Occasionally, articles in an RSS feed aren't presented in a predictable order when placed in a widget. If you are the publisher of a feed, here are some tips to get your feeds to show properly in NewsGator widgets. If you are using feeds from another publisher, this article will be useful as far as what to look for and troubleshooting. For more information visit the wiki article on this: http://developer.newsgator.com/wiki/index.php?title=Ensure_Your_Post_Items_Appear_in_the_Correct_Order.
First of all, you want to ensure that the publish date is the proper format in the feed. Using the ISO standard is the safest approach since it will be parsed by RSS readers more reliably than other methods (more info on ISO 8601: http://www.w3.org/TR/NOTE-datetime). However, a non-ISO pub date like "Mon, 06 Oct 2008 15:23:56 GMT" will be picked up properly by NewsGator's retrieval service.
Secondly, make sure you present the pub date in the correct time zone. There are a couple ways to do this:
- Include the time zone designator (here in Denver we're MDT).
- Denote the difference in your local time from GMT. For example, if it's 2pm in Denver, it is 8pm GMT. This is represented by showing the (6 hour) difference after the time.
- Show the GMT time that the article was published (with "GMT" as the time zone code).
If I published an article today at 2pm MDT, here's how the publish date in the feed could look:
- With the local time zone code: <pubDate>Mon, 06 Oct 2008 15:03:56 MDT</pubDate>
- With the difference between GMT and my local time: <pubDate>Mon, 06 Oct 2008 15:03:56 -0600</pubDate>
- With the GMT time that the article was published: <pubDate>Mon, 06 Oct 2008 21:03:56 GMT</pubDate>
Whatever we pick up in the pubdate property gets stored as GMT in our database. It's very important to note that by using the offset (second method), there is no consideration for daylight savings. If you don't want to worry about how the time will be interpreted, use GMT! Here's a handy time zone converter: http://www.timezoneconverter.com/cgi-bin/tzc.tzc
Some final notes:
No pubdate in the feed? There may be some weirdness. Our content retrieval system will store the article with a pub date set to the time that we pick it up. So if we visit a feed that has 5 new articles, those articles will have the exact same pub date and they may display in the widget in a different order than what you see in the feed.
So what if a pub date exists in the future? For a regular widget, where the feed has been added in the "Your Content" tab in Editor's Desk, the article will not show up until that time has occurred. But if you're using dynamic content or search in the widget, a pub date in the future can show up.
And remember, if you still have any troubles, simply use the Manage Articles utility in Editor's Desk!
Using a timezone specifier like MDT is tricky, because you must remember to change the specifier for daylight savings time (eg, to MST) for half the year. If you mess that up then half your posts will be off by an hour.
So yeah, definitely best to use GMT or UTC time.
Posted by: Brian R | October 07, 2008 at 01:41 PM
If you mess that up then half your posts will be off by an hour.
Posted by: aion kinah | July 14, 2009 at 11:49 PM