From 9316d49e685f710b784a47dba559ef3507549f51 Mon Sep 17 00:00:00 2001 From: Stefan Breunig Date: Fri, 8 Feb 2013 17:25:35 +0100 Subject: [PATCH] get time for chat input differently, so it reflects the local time --- code/chat.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/chat.js b/code/chat.js index 0dc53f1e..e270cf6e 100644 --- a/code/chat.js +++ b/code/chat.js @@ -616,7 +616,9 @@ window.chat.setupTime = function() { var updateTime = function() { if(window.isIdle()) return; var d = new Date(); - inputTime.text(d.toISOString().slice(11, 16)); + var h = d.getHours() + ''; if(h.length === 1) h = '0' + h; + var m = d.getMinutes() + ''; if(m.length === 1) m = '0' + m; + inputTime.text(h+':'+m); // update ON the minute (1ms after) setTimeout(updateTime, (60 - d.getSeconds()) * 1000 + 1); };