[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

changing timezones

Sam Joseph

6/6/2007 7:25:00 PM

Hi,

Does anyone know how I can manipulate the timezone in ruby? I know that
I get a date from unix seconds like Time.at(secs), but how can I get
something like Time.at(secs, time_zone)? At the moment Time.at appears
to pull in the environment setting for timezone, which I could reset,
but that is not ideal ...

Many thanks in advance.
CHEERS> SAM

1 Answer

Pau Garcia i Quiles

6/6/2007 7:42:00 PM

0

Hello,

TzInfo is your friend:
http://tzinfo.ruby...

--
Pau Garcia i Quiles
http://www.e...
(Due to the amount of work, I usually need 10 days to answer)



Quoting Sam Joseph <sam@neurogrid.com>:

> Hi,
>
> Does anyone know how I can manipulate the timezone in ruby? I know that
> I get a date from unix seconds like Time.at(secs), but how can I get
> something like Time.at(secs, time_zone)? At the moment Time.at appears
> to pull in the environment setting for timezone, which I could reset,
> but that is not ideal ...
>
> Many thanks in advance.
> CHEERS> SAM
>
>