Copia el siguiente comando
dentro HEAD><HEAD de tu documento
<SCRIPT LANGUAGE="JavaScript">
//Este Java Script y mas en http://gratisss.bizland.com
<!--- Oculto para browsers antiguos
function WinOpen()
{
alert('\nPagina se abrira completamente.\n\nUse Ver/Documento desde la barra menu.\n\nCierre la nueva ventana para retornar a esta pagina. ');
window.open("scripts/script_reloj3.htm","DisplayWindow","menubar=yes");
window.open("scripts/script_reloj3.htm","DisplayWindow","menubar=yes"); // doble para Macs
}
//Fin-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
var timerID = null
var timerRunning = false
function stopclock(){
//
if(timerRunning)
clearTimeout(timerID)
timerRunning = false
}
function startclock(){
// Estar seguro que el reloj se ha detenido
stopclock()
showtime()
}
function showtime(){
var now = new Date()
var hours = now.getHours()
var minutes = now.getMinutes()
var seconds = now.getSeconds()
var timeValue = "" + ((hours > 12) ? hours - 12 : hours)
var timeValue1 = "" + ((hours < 10) ? "0" : "") + hours
timeValue += ((minutes < 10) ? ":0" : ":") + minutes
timeValue1 += ((minutes < 10) ? ":0" : ":") + minutes
timeValue += ((seconds < 10) ? ":0" : ":") + seconds
timeValue1 += ((seconds < 10) ? ":0" : ":") + seconds
timeValue += (hours >= 12) ? " P.M." : " A.M."
<!-- timeValue1 += (hours >= 12) ? " P.M." : " A.M."-->
document.gratisss.juanpi.value = timeValue
document.gratisss1.juanpi1.value = timeValue1;
timerID = setTimeout("showtime()",1000)
timerRunning = true
}
//-->
</SCRIPT>
Copia el siguiente comando
dentro BODY><BODY de tu documento
onLoad="startclock()"
Formulario para formato
reloj Normal, copialo donde quieras dentro de tu documento
<td width="50%">
<form name="gratisss" onSubmit="0">
<table border="3" cellpading="3" cellspacing="4" width="30%" bgcolor="#0099CC">
<tr>
<th colspan="3" width="40%"><font color="#FFFFFF">NORMAL</font></th>
</tr>
<tr align="center">
<td colspan="3"><input type="text" name="juanpi" size="14"></td>
</tr>
</table>
</FORM>
Formulario para formato
reloj Militar, copialo donde quieras dentro de tu documento
</td>
<td width="50%">
<form name="gratisss1" onSubmit="0">
<table border="3" cellpading="3" cellspacing="4" width="30%" bgcolor="#0099CC">
<tr>
<th colspan="3"><font color="#FFFFFF">MILITAR</font></th>
</tr>
<tr align="center">
<td colspan="3"><input type="text" name="juanpi1" size="10"></td>
</tr>
</table>
</FORM>