laduncan Posted August 14, 2007 Share Posted August 14, 2007 I've run into a problem, and I'm assuming it's a simple fix, but I can't figure it out. I'm using lastRSS.php to parse some internal RSS feeds, and it appears to be reading the feed timestamp as GMT (I'm in CDT). It uses this code to format the text: // convert pubDate to specified date format $result['items'][$i]['pubDate'] = date($this->date_format, $timestamp); Date_format is null, though I've tried adding different date() parameters to date_format without luck. The timestamp of a feed might be 8:04am, and lastRSS will read that as 3:04am. If I change the local timezone, this time changes. At the moment, I've just hacked it with $timestamp = strtotime('+5 hours',$timestamp); but this won't work when we go on and off daylight savings time, and, anyway, I want to figure out how to make this work correctly. Do you have any ideas? Thanks very much! Lane Quote Link to comment https://forums.phpfreaks.com/topic/64880-lastrss-and-timezone-problem/ Share on other sites More sharing options...
laduncan Posted August 15, 2007 Author Share Posted August 15, 2007 For those who may be interested, it appears to be a problem not with the lastrss.php script, but rather with the mediaiwiki feed.php script. It's marking the timestamp as GMT. -Lane Quote Link to comment https://forums.phpfreaks.com/topic/64880-lastrss-and-timezone-problem/#findComment-324774 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.