function reloj() {
	var Digital=new Date();
	var hora=Digital.getHours();
	if (hora < 10) { hora = "0"+hora; }
	var minuto=Digital.getMinutes();
	if (minuto < 10) { minuto = "0"+minuto; }

	var segundo=Digital.getSeconds();
	//alert(hora+":"+minuto+":"+segundo);
	document.getElementById('mostrar').innerHTML = hora+":"+minuto+":"+segundo;

}
setInterval("reloj();", 1000);
//<div id="mostrar"></div>