how to convert server datetime to client machine datetime for the website.

Posted by Shailendra on Stack Overflow See other posts from Stack Overflow or by Shailendra
Published on 2010-06-08T09:33:00Z Indexed on 2010/06/08 9:52 UTC
Read the original article Hit count: 190

Filed under:
|

I have datetime fieldI have datetime field into the database which stores the universal time i.e. UTC time. I want to show the datetime at the client machine in clients time zone and format.

Example: Someone from US updated the database field for a site and it is stored into the UTC format. Someone from India goes and sees the site . What i want is that the person from India sees the time in IST or from Australia sees in his local machines time format not the server time format and zone.

Whats the best way to do this ?? Please paste code snippet if you have.

Thanx in advance!

© Stack Overflow or respective owner

Related posts about database

Related posts about datetime