diff options
author | Arun Persaud <arun@nubati.net> | 2007-12-17 00:44:09 +0100 |
---|---|---|
committer | Arun Persaud <arun@nubati.net> | 2007-12-17 00:51:18 +0100 |
commit | e7e64b1ada481710704c16bfb8ee4a7c337dc8f1 (patch) | |
tree | 220fa54af83c921393d006e53f3f026cf4745be5 /output.php | |
parent | acf6c5f97944366952e6b373a4d59cecd08b658e (diff) | |
download | e-DoKo-e7e64b1ada481710704c16bfb8ee4a7c337dc8f1.tar.gz e-DoKo-e7e64b1ada481710704c16bfb8ee4a7c337dc8f1.tar.bz2 e-DoKo-e7e64b1ada481710704c16bfb8ee4a7c337dc8f1.zip |
BUGFIX: local time should now work correctly
had to reset the timezone to the local time. added a config parameter to store the local timezone.
Diffstat (limited to 'output.php')
-rw-r--r-- | output.php | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -366,6 +366,7 @@ function output_footer() function output_status() { + global $defaulttimezone; if(isset($_SESSION["name"])) { $name = $_SESSION["name"]; @@ -379,10 +380,11 @@ function output_status() /* last logon time */ $myid = DB_get_userid_by_name($name); $zone = DB_get_user_timezone($myid); - date_default_timezone_set($zone); $time = DB_get_user_timestamp($myid); + date_default_timezone_set($defaulttimezone); $unixtime = strtotime($time); + date_default_timezone_set($zone); echo "<div class=\"lastlogin\">last login: ".date("r",$unixtime)."</div>"; }; |