Javascript Error Message When Adding Milliseconds To A Clock
I keep getting this error message: Uncaught SyntaxError: Unexpected identifier when adding milliseconds to a clock. I am copying it out of a book, so I am not sure what is wrong.
Solution 1:
Looks like you're missing a +
here:
document.write(hours + ":" + minutes + ":" + seconds + ":" mil);
//--------------------------------------------------------^^^^
Solution 2:
The line
document.write(hours + ":" + minutes + ":" + seconds + ":" mil);
should read
document.write(hours + ":" + minutes + ":" + seconds + ":" + mil);
There is a +
missing before mil
Solution 3:
you missed a +
document.write(hours + ":" + minutes + ":" + seconds + ":" + mil);
Post a Comment for "Javascript Error Message When Adding Milliseconds To A Clock"