diff options
author | thomascube <thomas@roundcube.net> | 2008-09-03 16:03:19 +0000 |
---|---|---|
committer | thomascube <thomas@roundcube.net> | 2008-09-03 16:03:19 +0000 |
commit | c8ae2497b7e4c7393210ed186acd672a0040389f (patch) | |
tree | b21442a9fff2d15cee5809db3d532d8ef378da37 /program/js | |
parent | 7003206d64c83534f29d1eb9dfc53edf993baf5b (diff) |
Auto-detect client language and timezone if desired by config/prefs
Diffstat (limited to 'program/js')
-rw-r--r-- | program/js/app.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/program/js/app.js b/program/js/app.js index ff6ff8cf3..7ba8572b3 100644 --- a/program/js/app.js +++ b/program/js/app.js @@ -318,13 +318,19 @@ function rcube_webmail() case 'login': var input_user = rcube_find_object('rcmloginuser'); var input_pass = rcube_find_object('rcmloginpwd'); + var input_tz = rcube_find_object('rcmlogintz'); + if (input_user) input_user.onkeyup = function(e){ return rcmail.login_user_keyup(e); }; if (input_user && input_user.value=='') input_user.focus(); else if (input_pass) input_pass.focus(); - + + // detect client timezone + if (input_tz) + input_tz.value = new Date().getTimezoneOffset() / -60; + this.enable_command('login', true); break; |