![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
03/08/2004, 15:50
|
![Avatar de KarlanKas](http://static.forosdelweb.com/customavatars/avatar11549_2.gif) | Moderador extraterrestre | | Fecha de Ingreso: diciembre-2001 Ubicación: Madrid
Mensajes: 6.987
Antigüedad: 23 años, 1 mes Puntos: 61 | |
Prueba con esto: Código HTML: <html>
<head>
<title>Untitled</title>
</head>
<script language="JavaScript">
var inicio;
var fin;
var nume;
function calcular(){
fin = new Date();
var nume = Math.round((fin-inicio)/1000);
alert("Has tardado en dar al botón "+nume+" segundos\ndesde que se cargó la página.");
}
</script>
<body onload="inicio=new Date();">
<input type="submit" onclick="calcular()">
</body>
</html>
__________________ Cómo escribir
No hay pregunta tonta, sino tonto que quiere seguir en la ignorancia.
Última edición por KarlanKas; 03/08/2004 a las 15:51 |