Hi all,
My organisation's intranet home page has an RSS feed of wordpress-based blog posts being pulled in, but the published date and time is coming over as the UTC time, not the correct time zone (UTC+11), which the blog is set to.
Everything else in Squiz is using the correct time zone.
Any ideas?
RSS Feed Item Published Date
Any chance the RSS feed has the UTC time in it rather than the local time?
Hi there, we are having the same problem when we have a blog feed being pulled in via the RSS Data Source.
using the keyword %data_source_record_set_pubdate%, it shows the date as "Wed, 23 Mar 2011 18:00:38 +0000"
however the time in its original blog is "Thursday, 24 March 2011 7:00 a.m."
Any thoughts? or need JS to format the date time?
Thanks.
[quote]
Where are you pulling that date/time from? A field in the RSS feed?
[/quote]
Yes, the published date is coming from the feed (ds__pubdate), and I checked, the system timezone in Matrix is correct.
Is there a way to adjust the 'ds__pubdate' by a specified amount (equal to the timezone offset)?
[quote]
Any chance the RSS feed has the UTC time in it rather than the local time?
[/quote]
No, the blog also has the correct time zone. I don't know about how Wordpress RSS presents the timestamps, or how Matrix reads them.
Maybe Wordpress presents a timestamp in UTC, as well as the timezone of the article, but Matrix only brings in the timestamp…?
[quote]
No, the blog also has the correct time zone. I don't know about how Wordpress RSS presents the timestamps, or how Matrix reads them.
Maybe Wordpress presents a timestamp in UTC, as well as the timezone of the article, but Matrix only brings in the timestamp…?
[/quote]
I suspect WordPress is producing an RSS feed with UTC time, which is what Matrix gets. Matrix doesn't have a way to convert this into your local time. See if you can get the WordPress feed to insert the local time into the RSS feed.
[quote]
I suspect WordPress is producing an RSS feed with UTC time, which is what Matrix gets. Matrix doesn't have a way to convert this into your local time. See if you can get the WordPress feed to insert the local time into the RSS feed.
[/quote]
Apparently all RSS feeds use UTC time… so it seems every RSS reader should have the ability to adjust for the local time zone.
Is this a functionality we can expect from Matrix in the future?
Is there somewhere on this site that we can suggest new features?
[quote]
Is there somewhere on this site that we can suggest new features?
[/quote]
On our issue tracker: http://bugs.matrix.squiz.net
[quote]
I suspect WordPress is producing an RSS feed with UTC time, which is what Matrix gets. Matrix doesn't have a way to convert this into your local time. See if you can get the WordPress feed to insert the local time into the RSS feed.
[/quote]
Fixed!
Okay, so the solution we used (needed to be implemented on the Wordpress side of things)
In wp-includes/feed-rss2.php
[font="Courier New"]get_post_time('Y-m-d H:i:s', true)[/font]
changed '[font="Courier New"]true[/font]' to '[font="Courier New"]false[/font]'
(that's in the [font="Courier New"]<pubDate></pubDate>[/font] section of the xml file it generates)
We're looking for a solution in Matrix, editing the output of the RSS feed asset listing.
try using matrix keyword modifiers.
%ds__pubdate^date_format:D, d M Y - g i a%
--------------------------------------------------------------------------
[quote]
Fixed!
Okay, so the solution we used (needed to be implemented on the Wordpress side of things)
In wp-includes/feed-rss2.php
[font="Courier New"]get_post_time('Y-m-d H:i:s', true)[/font]
changed '[font="Courier New"]true[/font]' to '[font="Courier New"]false[/font]'
(that's in the [font="Courier New"]<pubDate></pubDate>[/font] section of the xml file it generates)
We're looking for a solution in Matrix, editing the output of the RSS feed asset listing.
[/quote]