In ruby on rails, how to display the time correctly in the client?

Meerojepe

New Member
I have a \[code\]ruby-on-rails\[/code\] server that implements a \[code\]JSON\[/code\] \[code\]REST\[/code\] API e.g.\[code\]http://my-server.com/end_of_promotion.json\[/code\]Currently, the answer is: \[code\]{ date: "2013-03-31T14:29:16Z"}\[/code\]In my \[code\]model\[/code\], date is an attribute of type: \[code\]datetime\[/code\].Now, I would like the client to display this date in the user timezone.How should I design the API and the client code to make it happen?
 
Top