Forum OpenACS Development: Re: TimeZone Setup

Collapse
2: Re: TimeZone Setup (response to 1)
Posted by Dave Bauer on
Yes it is because of daylight savings time.
Collapse
Posted by Cesareo Garci­a Rodicio on
Hi Dave

So. Do I have to change it every DST change?

Because, my problem was with two things:

-In Calendar (view day)
-Custom code:

"
set hora_server [ns_fmttime [ns_time] "%Y-%m-%d %H:%M:%S"]
set hora_utc [lc_time_local_to_utc $hora_server ]
set hora_local [lc_time_system_to_conn $hora_server ]
"

I've found some inconsistencies. For example, hora_server is one hour more that real time. hora_local is fine but hora_utc is wrong (one hour less).

So how can I do the right setup? Do you know?
Server Time: GMT -7
User Local Time: GMT -5 (even though I could change sometimes)

Thanks
Cesareo