首页 > 其他 > 详细

计算一年后的日期

时间:2017-11-12 16:09:15      阅读:227      评论:0      收藏:0      [点我收藏+]
<!DOCTYPE html>
<html>
<head>
    <title>日期计算</title>
</head>
<body>
<script type="text/javascript"> var months=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]; var nowDate=new Date(); nowDate.setMonth(nowDate.getMonth()+12); document.write("Date 12 months ahead is "+nowDate.getDate()); document.write(" "+months[nowDate.getMonth()]); document.write(" "+nowDate.getFullYear());
</script> </body> </html>

 

计算一年后的日期

原文:http://www.cnblogs.com/qfdy123/p/7821794.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!