Ok, noob mistake. I added onload = "displayTime()" to the opening body tag, and now my output now says "Time 1:1" which tells me there's another problem besides the fact that it's not working.
I need the minutes to only start counting after seconds reach more than 59 seconds. My code now looks like this:
<html> <head> <title>Timer</title> <script type=\"text/javascript\"> var seconds = 0; var minutes = 0;
function countSecs() { seconds++; } if (seconds > 59) { function countMins() { minutes++; } }
I'm probably going about this the wrong way, but hopefully, someone can point me in the right direction.
Thanks.
I need the minutes to only start counting after seconds reach more than 59 seconds. My code now looks like this:
But my output is still Time 1:1.
can also add one more section to get MS and change the timeout speed: