• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
GMT dropdown autoselect according to local GMT?

[eluser]Tyler Diaz[/eluser]
If the topic title did not explain itself too clearly, what I want to do is: Take the date helper GMT dropdown and make it auto select the GMT that corresponds to what may seem as the default one. For example, my GMT is GMT-5. How could I make the dropdown be default selected at GMT-5?

I tried experimenting and searching but did not have much luck. Thanks in advance, Tyler Diaz.

You need to use UM5 to select GMT-5:

Check timezone reference table here - http://ellislab.com/codeigniter/user-gui...elper.html

[eluser]Tyler Diaz[/eluser]
I understood that part, I have read the date helper past of the guide extensively.

But how would I make it auto select according to the GMT the user has. A case scenario would be supposing you live in Texas, and I live in florida - Both different time zones. When you see the dropdown it is auto selected to the Texas GMT and when I see the dropdown it is auto selected to the florida GMT.

I guess you need to use javascript to detect the user's timezone.
Have a look at http://www.onlineaspect.com/2007/06/08/a...avascript/

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.