yyyy/M/d h:m:s 转换成 yyyy-MM-dd hh:mm:ss

  var arrTime = (dtime).replace("/", "-").replace("/", "-");
var deTime = arrTime.split(" ");
var ss = deTime[];
var s1 = ss.split("-");
var dd = deTime[];
var d1 = dd.split(":");
var newStr = s1[] + "-" + (s1[].length > ? '' : '') + s1[] + "-" + (s1[].length > ? '' : '') + s1[];
var Str = (d1[].length > ? '' : '') + d1[] + ":" + (d1[].length > ? '' : '') + d1[] + ":" + (d1[].length > ? '' : '') + d1[];
var times = newStr + " " + Str;
上一篇:ROM与RAM知识


下一篇:poj 2411 Mondriaan's Dream_状态压缩dp