js获取当前年月日时分

2023-02-12,,,

function GetDate(){
var now = new Date();
var year = now.getFullYear();    //年
var month = now.getMonth() + 1; //月
var day = now.getDate();   //日
var hh = now.getHours();   //时
var mm = now.getMinutes(); //分
}

js获取当前年月日时分的相关教程结束。

《js获取当前年月日时分.doc》

下载本文的Word格式文档,以方便收藏与打印。