I just wrote a helper that handles the time difference and wrapped all my 
display dates with that. If I want something quick and dirty I do just what you 
did and pass it the time and it returns the time -7. If you want to get really 
fancy you can get their IP, like this example 
http://redfursnake.blogspot.com/2010/02/get-your-users-time-zone-from-their-ip.html
 

I've done something similar to this.

--
Jason Liebrecht

On May 12, 2011, at 8:16 PM, Guyren Howe <[email protected]> wrote:

> I’ve got a Rails 3 app where all the data is in California.
> 
> I do this in config/application.rb:
> 
>    config.time_zone = "Pacific Time (US & Canada)"
> 
> despite this, Rails continues to try to help me by converting to and from 
> UTC, in some places but not in others.
> 
> Is there any way to just turn off the madness? Either a “stop helping” 
> option, or something that will *actually* convert all the times I’m using to 
> and from UTC without my worrying about it?
> 
> Right now, my code is littered with adding and subtracting 7 hours when I do 
> things in the places where it’s helping, and that way lies madness.
> 
> -- 
> SD Ruby mailing list
> [email protected]
> http://groups.google.com/group/sdruby

-- 
SD Ruby mailing list
[email protected]
http://groups.google.com/group/sdruby

Reply via email to