X

現在の時間を文字列で取得

/*
* 現在の時間を文字列で取得
*/
function getTime(){
tmp = new Date();
return tmp.getFullYear()+’-‘+(tmp.getMonth()+1)+’-‘+tmp.getDate()+’ ‘+
tmp.getHours()+’:’+tmp.getMinutes()+’:’+tmp.getSeconds();
}

健巳:
Related Post