nextcloud/core/js/visitortimezone.js

13 lines
385 B
JavaScript
Raw Normal View History

/* global jstz */
2013-01-22 00:10:44 +04:00
$(document).ready(function () {
$('#timezone_offset').val((-new Date().getTimezoneOffset() / 60));
$('#timezone').val(jstz.determine().name());
// only enable the submit button once we are sure that the timezone is set
var $loginForm = $('form[name="login"]');
if ($loginForm.length) {
$loginForm.find('input#submit').prop('disabled', false);
}
2014-03-01 05:46:27 +04:00
}
);