function dateForm(time){ ???????????????var unixTimestamp = new Date( 1477386005*1000 ); ???????????????commonTime = unixTimestamp.toLocaleString(); ???????????} ???????????Date.prototype.toLocaleString = function() { ???????????????return this.getFullYear() + "/" + (this.getMonth() + 1) + "/" + this.getDate() + "/" + this.getHours() + ":" + this.getMinutes() + ":" + this.getSeconds(); ???????????};
new Data(‘毫秒数’)是标准时间,
new Data().getTime()是把标准时间转换成毫秒数
js 毫秒转换为标准时间
原文地址:http://www.cnblogs.com/mmzuo-798/p/7591087.html