Ruby on Rails
Monday, December 3, 2012
Time. New uses the default system timezone when no one is given, so u say that you want 9:30 of your systems timezone in GMT, which is probably 8:30 GMT, depending on your local time zone.
You have to add the corresponding parameter to Time. New. Take a look at its documentation.
Am 03.12.2012 12:10 schrieb "Erwin" <yves_dufour@mac.com>:
-- I am storing a Time record w a timezone like : an event at 9:30 in Paris time(rdb:1) Time.zone = "Europe/Paris""Europe/Paris"(rdb:1) Time.new(2012, 12, 3, 9, 30, 0).in_time_zone("Europe/Paris")Mon, 03 Dec 2012 09:30:00 CET +01:00Now I want to store another event occurring also at 9:30 but in London time/London"(rdb:1) Time.new(2012, 12, 3, 9, 30, 0).in_time_zone("Europe/London")Mon, 03 Dec 2012 08:30:00 GMT +00:00which is wrong .... I want this event at 9:30 GMT !!what's wrong there ?thanks for feedback--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/KbjGqEvgFW0J.
For more options, visit https://groups.google.com/groups/opt_out.
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment