var clockID = 0;

function UpdateClock()
{
	if(clockID)
	{
		clearTimeout(clockID);
		clockID  = 0;
	}

	var tDate = new Date();
	
	var strMinutes	= '';
	
	strMinutes	+= tDate.getMinutes();
	
	if(strMinutes.length == 1)
	{
		strMinutes = '0' + strMinutes;
	}	
	
	document.getElementById("txtTime").innerHTML = "" + tDate.getHours() + ":" + strMinutes;
	
	clockID = setTimeout("UpdateClock()", 1000);
}

function StartClock()
{
	clockID = setTimeout("UpdateClock()", 500);
}

function KillClock()
{
	if(clockID)
	{
		clearTimeout(clockID);
		clockID  = 0;
	}
}



