[wp-hackers] Timezones, server settings, and WP dates

Eric A. Meyer eric at meyerweb.com
Thu Jan 27 17:14:12 GMT 2005


At 11:45 -0500 1/27/05, Carthik Sharma wrote:
>On Thu, 27 Jan 2005 11:36:21 -0500, Eric A. Meyer <eric at meyerweb.com> wrote:
>
>>      I already set that to -5.  Sorry, I forgot to mention that in my
>>  original post.  Having it set doesn't do anything to fix the 'UTC' or
>>  the '+0000'.
>>
>
>I am sorry if that doesn't work. If it doesn't it must be a bug, since
>it's expected to work.

    I don't understand why you say that.  The 'T' in the php_date 
format is expected to return the server's timezone setting, and it 
does: the server is configured to UTC.  The actual times are properly 
offset (if I post at 19:31 EST, which is 00:31 UTC, WP returns 19:31) 
but the timezone designator is wrong (it claims UTC when I'm in EST).
    The feed offsets are another problem, and I can see that might be 
some kind of bug-- but again, they're apparnently returning the 
server's offset, not the WP offset.  Is there a simple way to pull 
the offset from the WP settings so I can at least fix the feeds?  I'm 
not shy about hacking my PHP, but I'd like to do it intelligently 
instead of just putting in static timezone designators.

>>      But how?
>
>I will look into this the soonest I can. The problem, though, is that
>it would be one more option, and little more confusion.

    At the moment, the lack of the option is adding to confusion for 
everyone who subscribes to my feeds and does date sorting.  My view 
is that I'd rather have one person (a WP user) be momentarily 
confused, and just once, than have confusion distributed to a site's 
readers.  If it's sufficiently problematic, of course, you could just 
hide it in some sort of advanced-option interface.
    Note also that in cases where multiple WP installs are running on 
a single machine, there is the potential for even more confusion. 
Molly Holzschlag and I, for example, run on the same server, but are 
three time zones apart.  Both our feeds have local times incorrectly 
given +0000 offsets.  Thus, if we both post at a one-minute offset-- 
say, 1601PST and 1900EST-- her post will appear to be not quite three 
hours older than mine, because her feed will report that she posted 
at 1601+0000 and I posted at 1900+0000.  In fact, I posted at 
1900-0500 (0000 UTC) and she at 1601-0800 (0001 UTC); if those 
offsets appeared correctly, then the posts would be sorted correctly.

>I would rather
>live with changing it once or twice manually every year, like I do
>with my clocks.

    See, I think having to change my clocks twice a year is silly: 
they ought to know when to change and just do it, instead of 
requiring me to do it manually.  Different approaches to life, I 
guess.

-- 
Eric A. Meyer  (eric at meyerweb.com)
Principal, Complex Spiral Consulting   http://complexspiral.com/
"CSS: The Definitive Guide," "CSS2.0 Programmer's Reference,"
"Eric Meyer on CSS," and more    http://meyerweb.com/eric/books/


More information about the hackers mailing list