CEIP.getWinterTimezoneOffset Member
Gets a date-independent timezone offset for the user.
Syntax
object.getWinterTimezoneOffset();
Returns
A value which is constant throughout the year for a given timezone.
Remarks
The calculation takes the two solstices, using approximate dates 21st June and 21st December, and chooses the most "behind" timezone offset of them as the winter timezone offset.
See Also
Source Code
function ceip_getwintertimezoneoffset()
{
var d1 = new Date();
d1.setMonth(5);
d1.setDate(21);
var d2 = new Date();
d2.setMonth(11);
d2.setDate(21);
return Math.max(d1.getTimezoneOffset(), d2.getTimezoneOffset());
}