var relojid=new Array()
var relojidoutside=new Array()
var i_reloj=-1
var thistime= new Date()
var hours=thistime.getHours()
var minutes=thistime.getMinutes()
var seconds=thistime.getSeconds()
if (eval(hours) <10) {hours="0"+hours}
if (eval(minutes) < 10) {minutes="0"+minutes}
if (seconds < 10) {seconds="0"+seconds}
var thistime = hours+":"+minutes
	
function writereloj() {
	i_reloj++
	if (document.all || document.getElementById || document.layers) {
		relojid[i_reloj]="reloj"+i_reloj
		document.write("<span id='"+relojid[i_reloj]+"' style='position:relative'>"+thistime+"</span>")
	}
}

function relojon() {
	thistime= new Date()
	hours=thistime.getHours()
	minutes=thistime.getMinutes()
	seconds=thistime.getSeconds()
	if (eval(hours) <10) {hours="0"+hours}
	if (eval(minutes) < 10) {minutes="0"+minutes}
	if (seconds < 10) {seconds="0"+seconds}
	thistime = hours+":"+minutes
		
	if (document.all) {
		for (i=0;i<=relojid.length-1;i++) {
			var thisreloj=eval(relojid[i])
			thisreloj.innerHTML=thistime
		}
	}
	
	if (document.getElementById) {
		for (i=0;i<=relojid.length-1;i++) {
			document.getElementById(relojid[i]).innerHTML=thistime
		}
	}
	var timer=setTimeout("relojon()",1000)
}
window.onload=relojon