Convert UTC to local time in Rails 3
Time#localtime will give you the time in the current time zone of the machine running the code: > moment = Time.now.utc => 2011-03-14 15:15:58 UTC > moment.localtime => 2011-03-14 08:15:58 -0700 Update: If you want to conver to specific time zones rather than your own timezone, you’re on the right track. However, instead of worrying … Read more