Date.getMonth() 會依本地時間回傳日期物件中的月份,範圍為 0 到 11。
new Date().getMonth()
0 代表一月,11 代表十二月,使用時常需加 1 才能符合一般月份顯示。
若需要 UTC 月份,可使用 getUTCMonth()。