草庐IT

getUTCMilliseconds

全部标签

javascript - 为什么存在 `getUTCSeconds` 和 `getUTCMilliseconds` 函数?

这些值不会总是与getSeconds和getMilliseconds相同吗? 最佳答案 本地时间和UTC时间之间的调整基于指定为毫秒数的偏移量。http://es5.github.com/#x15.9.1.7说15.9.1.7LocalTimeZoneAdjustmentAnimplementationofECMAScriptisexpectedtodeterminethelocaltimezoneadjustment.ThelocaltimezoneadjustmentisavalueLocalTZAmeasuredinmilli