display users local time
| From: | scottrus at ipass dot net | Date: | Mon, 14 Aug 2000 15:58:30 +0000 |
| Subject: | display users local time | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-11742@lists.php.net to get a copy of this message | ||
Greets all -
I seem to be missing something obvious. I want to display the date/time according to the users local
settings. Best as I can see I need to know two vars to do this, the local users LANG and the TZ they
are
in.
Does the browser pass this info in the header somewhere were php can read it? I don't want to
hard code
in to display the time / date in any one region.
Once I know the LANG and the TZ I know I can use the setlocale(), strftime(), and other date / time
functions to manuplate the date / time in to what I want. I'm just missing where to get the
users local
settings from...
Thanks for any help.
--
Scott