js内置date类
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title>内置Date日期类</title>
</head>
<body>
<script type="text/javascript">
var nowTime=new Date();
document.write(nowTime.toString());
var strTime=nowTime.toLocalString();
document.write(strTime);
var year=nowTime.getYear();
year=nowTime.getFullYear();
var time=nowTime.getTime();
alert(time);
</script>
</body>
</html>
总结很重要哦 方法得当,坚持会有奇迹哦