I wrote some javascript in hopes of outputting time as hh:mm
(EG: 15:45
)
However my code is returning Nan:Nan
var timer = 24;
var time1 = new Date();
time1.setHours(time1.getHours + (6));
time1.setMinutes(time1.getMinutes());
document.write(time1.toString("hh:mm"));
Can someone help me understand why this isn't working as intended?