js 取该月的天数

function getDaysInMonth(year, month) {
var temp = new Date(year, month, 0);
return temp.getDate();
}

原文地址:https://www.cnblogs.com/lccnblog/p/3483289.html