Date and Timestamp Conversion

Date and timestamp conversion
var a = new Date();
a = dataInfo1[0].split(",")[i];
var b = Date.parse(a);
var c = b - 60 * 60 * 1000 ;
var d = new Date(c);
var e = d.getFullYear() + '/' + (d.getMonth() + 1) + '/' + d.getDate() + ' ' + d.getHours( ) + ':' + d.getMinutes() + ':' + d.getSeconds();

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324601224&siteId=291194637