[Zope] System DateTime issue - redux

complaw@hal-pc.org complaw@hal-pc.org
Fri, 19 Oct 2001 22:58:29 GMT


This is a subject that has come up on the list before, but never got a
resolution.  Evidently (at least on Linux systems), Zope takes the Universal
Date/Time (UDT) rather than the Local Date/Time (LDT).  Consequently, if you use
ZopeTime(), you have to make a correction (-5 hours if you are in
America/Chicago CDT).  

This is a wish list, I know, but for Zope 2.4.3, could there be a switch or flag
that can be set that says ZopeTime() will get the local time instead of
universal time?  That or use something like LocalTime() and thus leave
ZopeTime() alone?

Note, in your Python scripts, you can...

from time import time, localtime

.. but not in DTML, where the code for displaying time normally resides.


This isn't a trivial subject.  If you have a product that displays the time (as
some templates do for newbies or site developers) they don't know enough to
fiddle with the code to get the time displayed correctly if they happen to live
in a time zone other than the Product's author (meaning, the vast majority of
the planet).

Ron
 ./.