WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] UTC/GMT issues, confusion, problem (4 posts)

  1. seanmcauliff
    Member
    Posted 6 years ago #

    Having some problems understanding the publish times of posts, time zones, and how feed readers see time published. I've searched the forums and while I've found some information, I haven't found an answer to this specific issue - Here 's the deal:

    I'm in NYC. I have set, in the admin settings, my timezone to UTC - 4. This page correctly displays my current time, allowing for Daylight Savings. When I write posts or update them, the times are correct in the admin pages and on my blog. But when I look at the times in the xml source of my rss2 feed, the times are greater by 4 hours. So if I write or modify a post at 7am, the feed displays the pubDate as 11am. When I check a feed reader like Bloglines, it doesn't see the article update until 11am. So...

    Maybe this is all normal and I'm just not getting the whole timezone thing. Or is something off? I notice in the feed-rss2.php file is calles get_lastpostmodified('GMT')when it creates the pubDate. In the MySQL db for posts, the post_date and post_date_gmt entries for each post have the same 4 hour offset.

    All I really need to know is if I just need to wait to see Bloglines update, or is there something off here? SHould post_date and post_date_gmt have that offset? Is that the UTC - 4 and how is it working correctly if my posts don't show up in readers until 4 hours later. Thanks!

  2. Samuel Wood (Otto)
    Tech Ninja
    Posted 6 years ago #

    Maybe this is all normal and I'm just not getting the whole timezone thing.

    Yes, that's probably the case.

    Time is not a matter of timezone. For every second of every day, there's only one of them. Timezone just changes how you refer to one specific moment. Whether you refer to it in UTC or in EST or whatever, that moment is unique.

    So the post_date and post_date_gmt are actually the same times. The difference is just the timezone they are expressed in. The only reason this exists is because when you change your timezones, you may not want all your posts on the blog to shift themselves around by an hour. The post_date is a relative field to the timezone you were in when you published the post, the post_date_gmt is the absolute time you wrote that post, universal across all timezones.

    Now, your feed always uses the UTC time. Why? Because it's standard and universal and frankly your readers would probably like to know when you wrote your post. They really don't need to know what timezone you wrote it in, and their feedreaders will convert times to their own timezone anyway.

    Is that the UTC - 4 and how is it working correctly if my posts don't show up in readers until 4 hours later.

    When posts show up in readers has nothing to do with the timestamp they have, it's all down to how often the reader is updating from your feed. A feedreader only checks every so often, like, say every 12 hours. It gets it when it gets it and that's it. The timestamp has nothing to do with it.

  3. seanmcauliff
    Member
    Posted 6 years ago #

    Thanks - good info. One more question if possible, when I connect to Bloglines and I've subscribed to a feed (mine, for example), you're saying it doesn't check at that point to see if something's been updated. In other words, it doesn't look for updates every time I load Bloglines in the browser - you're saying it checks them at regular intervals and if I happen to load it after it has seen my update it shows up? Does that make sense?

    Somewhat off-topic I guess but anyway - thanks again...

  4. Samuel Wood (Otto)
    Tech Ninja
    Posted 6 years ago #

    In other words, it doesn't look for updates every time I load Bloglines in the browser - you're saying it checks them at regular intervals and if I happen to load it after it has seen my update it shows up? Does that make sense?

    Yes, and that's more or less exactly what it does. Feed readers that are online like that one or Google Reader or what have you read their feeds at semi-regular intervals, and then cache the results. You're not seeing the live feed, you're seeing whatever it has from the last time it checked.

Topic Closed

This topic has been closed to new replies.

About this Topic