1 var date = new Date(); 2 var year = date.getFullYear(); 3 var month = date.getMonth()+1; 4 var day = date.getDate(); 5 var hour = date.getHours(); 6 var minute = date.getMinutes(); 7 var second = date.getSeconds(); 8 alert(year+‘年‘+month+‘月‘+day+‘日 ‘+hour+‘:‘+minute+‘:‘+second);
时间: 2024-10-06 06:55:01