<html>
<head>
<script>
//这里传入的值一定要是数字,如果是字符串的话,需要先转为int型
var time = new Date(1530802447067);
console.log(time);//当前时间
console.log(time.getFullYear()+"年");//年份
console.log(time.getMonth()+1+"月");//月份
console.log(time.getDate()+"日");//几号
console.log("周"+time.getDay());//星期几
</script>
</head>
</html>
