]> git.mjollnir.org Git - moodle.git/commitdiff
Added timezone display to reduce confusion
authormoodler <moodler>
Sat, 7 Feb 2004 12:27:23 +0000 (12:27 +0000)
committermoodler <moodler>
Sat, 7 Feb 2004 12:27:23 +0000 (12:27 +0000)
mod/chat/view.php

index 9e1190e6134e5e17386e0187e6cdfc0b3c8fec13..3d1b910ef5609b71c59a9ae653553db5aebf61f8 100644 (file)
 
 
     if ($chat->chattime and $chat->schedule) {  // A chat is scheduled
-        echo "<p align=center>$strnextsession: ".userdate($chat->chattime)."</p>";
+        if (abs($USER->timezone) > 13) {
+            $timezone = get_string("serverlocaltime");
+        } else if ($USER->timezone < 0) {
+            $timezone = "GMT".$USER->timezone;
+        } else {
+            $timezone = "GMT+".$USER->timezone;
+        }
+        echo "<p align=\"center\">$strnextsession: ".userdate($chat->chattime)." ($timezone)</p>";
     } else {
         echo "<br />";
     }