与日期相关的JS

    xiaoxiao2022-07-04  101

    //获得当前日期 function getToday(){ var date=new Date(); var y = date.getFullYear(); var m = date.getMonth()+1; var d = date.getDate(); var todayStr=y+"-"+m+"-"+d; return todayStr; }

     

    最新回复(0)