time.zone â string
Instance Public methods
Returns the name of the time zone used for time. As of Ruby 1.8, returns âUTC'' rather than âGMT'' for UTC times.
1 2 3 4 | t = Time .gm( 2000 , "jan" , 1 , 20 , 15 , 1 ) t.zone #=> "UTC" t = Time .local( 2000 , "jan" , 1 , 20 , 15 , 1 ) t.zone #=> "CST" |
Please login to continue.