This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function updateClock ( ) | |
{ | |
var currentTime = new Date ( ); | |
var currentHours = currentTime.getHours ( ); | |
var currentMinutes = currentTime.getMinutes ( ); | |
var currentSeconds = currentTime.getSeconds ( ); | |
// Pad the minutes and seconds with leading zeros, if required | |
currentMinutes = ( currentMinutes < 10 ? "0" : "" ) + currentMinutes; |