there is a great little cfc @ cfczone.org that paul hastings
whipped up that does some timezone work.  best way, is to use
_javascript_ to get the time of the browser, set that timezone
offset as a cookie on the users browser, then access that
with the cookie. whatever you call it variable name in cf, and
do the time changes that way.  i had to use it extensively on our
site, www.navtrak.net, since we have clients whose vehicles
report in other time zones than where our servers are located, on the
east coast.

so, if you have any other questions i can probably help.

tony

-----Original Message-----
From: Jochem van Dieten [mailto:[EMAIL PROTECTED]
Sent: Sunday, November 16, 2003 3:55 PM
To: CF-Talk
Subject: Re: Compensating for Server Time

Chris Montgomery wrote:
>
> What's the best way to compensate for time on a server in a hosted
> environment when the time is set to a different time than a user's
local
> time zone? Ex: client is in Central Time, server is on Eastern Time
(one
> hour ahead); client wants everything to reflect local time.

I use the AT TIME ZONE functionality from SQL, it even
compensates for daylight savings time:

testDB=> select '2003-12-31 12:00:00' AT TIME ZONE 'cet';
       timezone
---------------------
  2003-12-12 12:00:00

testDB=> select '2003-07-31 12:00:00' AT TIME ZONE 'cet';
       timezone
---------------------
  2003-06-12 11:00:00

Jochem

--
Who needs virtual reality
if you can just dream?
     - Loesje


[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to