有趣的情人节时间密码

Sat Feb 14 21:09:00 UTC 2009
require 'rubygems'
require 'active_support'

Time.at 1234567890 # => Sat Feb 14 07:31:30 +0800 2009

Time.zone = "Beijing" # => "Beijing"

Time.zone.at 1234567890 # => Sat, 14 Feb 2009 07:31:30 CST +08:00

可惜今天一天都在加班,早上6:30才回,倒头就睡了,在不知不觉中就已经错过了这个有趣时间:(

Filed Under: Tags:

Comments

Have your say

A name is required. You may use HTML in your comments.