1.十三位数字的时间戳转换方法
var time = new Date(datetime).toLocaleString().replace(/年|月/g, "-").replace(/日/g, " ");
2.十位数字转换时需要将时间戳乘3使其成为十三位的时间戳;
var time = new Date(datetime*1000).toLocaleString().replace(/年|月/g, "-").replace(/日/g, " ");
时间:2019-02-23 23:53:32
1.十三位数字的时间戳转换方法
var time = new Date(datetime).toLocaleString().replace(/年|月/g, "-").replace(/日/g, " ");
2.十位数字转换时需要将时间戳乘3使其成为十三位的时间戳;
var time = new Date(datetime*1000).toLocaleString().replace(/年|月/g, "-").replace(/日/g, " ");
js angular 时间戳转换成日期格式 年月日 yyyy-MM-dd
2021-02-17
日期格式转换成时间戳格式php php日期转时间戳 指定日期转换成时间戳
2020-07-12