javascript 获取当前的年月日周几
//今天是年月日周几
var arr = ['日','一','二','三','四','五','六',]
var date =new Date();//记住这个是大写开头的Date
var year=date.getFullYear();
var month=date.getMonth()+1;
var dates=date.getDate();
var day=date.getDay();
var days=arr[day];
console.log('今天是'+year+'年'+month+'月'+dates+'日'+'周'+days)