JS获取 今天与明天的日期

//今天的日期
var today = new Date();
today.setTime(today.getTime());
var todayStr = today.getFullYear()+"-" + (today.getMonth()+1) + "-" + today.getDate();
//明天的日期
var tomorrow = new Date();
tomorrow.setTime(tomorrow.getTime() + 24*60*60*1000);
var tomorrowStr = tomorrow.getFullYear()+"-"+(tomorrow.getMonth()+1)+"-"+tomorrow.getDate();

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:http://www.duanlonglong.com/qdjy/309.html