龙空技术网

jquery 当天年月日+时间

PEK5SHL 179

前言:

当前姐妹们对“jquery时间日期轴”大致比较关切,你们都需要剖析一些“jquery时间日期轴”的相关资讯。那么小编在网络上汇集了一些有关“jquery时间日期轴””的相关文章,希望朋友们能喜欢,咱们快快来了解一下吧!

function getFormatDate() {    var nowDate = new Date();    var year = nowDate.getFullYear();    var month =      nowDate.getMonth() + 1 < 10        ? "0" + (nowDate.getMonth() + 1)        : nowDate.getMonth() + 1;    var date =      nowDate.getDate() < 10 ? "0" + nowDate.getDate() : nowDate.getDate();    var hour =      nowDate.getHours() < 10 ? "0" + nowDate.getHours() : nowDate.getHours();    var minute =      nowDate.getMinutes() < 10        ? "0" + nowDate.getMinutes()        : nowDate.getMinutes();    var second =      nowDate.getSeconds() < 10        ? "0" + nowDate.getSeconds()        : nowDate.getSeconds();    return (      year + "-" + month + "-" + date + " " + hour + ":" + minute + ":" + second    );  }//引用var Now_date_time = getFormatDate();

标签: #jquery时间日期轴