更新时间:2023-01-27 15:01:00
改编自: http://kennyshu.blogspot.com/2009/05/javascript-get-clients-timezone.html
<script type="text/javascript">
var gmtOffset
function timezone()
{
var localTime = new Date();
//this one will give you the GMT offset
gmtOffset = localTime.getTimezoneOffset()/60 * (-1);
}
</script>
然后将变量gmtOffset发回到您的应用程序中.
then post back the variable gmtOffset to your application.