今天调试一个倒计时javascript脚本,多次debug依然不能显示正确的时间,经过google才得知月份参数不对,date中的月份从0开始:

Method Description
getDate() Get the day as a number (1-31)
getDay() Get the weekday as a number (0-6)
getFullYear() Get the four digit year (yyyy)
getHours() Get the hour (0-23)
getMilliseconds() Get the milliseconds (0-999)
getMinutes() Get the minutes (0-59)
getMonth() Get the month (0-11)
getSeconds() Get the seconds (0-59)
getTime() Get the time (milliseconds since January 1, 1970)

相关文章:

  • 2021-09-22
  • 2022-12-23
  • 2022-12-23
  • 2021-10-31
  • 2022-12-23
  • 2021-09-03
  • 2022-01-15
  • 2021-05-22
猜你喜欢
  • 2021-08-11
  • 2021-09-28
  • 2021-06-26
  • 2021-06-24
  • 2021-06-27
  • 2021-07-11
  • 2022-12-23
相关资源
相似解决方案