Ver Mensaje Individual
  #2 (permalink)  
Antiguo 01/05/2006, 15:00
Avatar de Cap.Buscapina
Cap.Buscapina
 
Fecha de Ingreso: octubre-2004
Ubicación: Argentina
Mensajes: 836
Antigüedad: 19 años, 7 meses
Puntos: 4
para ello mejo setInterval

Cita:
<html>
<head>
<script>
var cc=0;
function tamanno(cuanto){
tabla=document.getElementById('tt');
cc=cc+cuanto;
tabla.width=parseInt(tabla.width)+cuanto;
document.getElementById('qq').innerHTML="Aumento:" +cc;
document.getElementById('ww').innerHTML="ancho:"+t abla.width;
if(cc<-99 || cc>99){
clearInterval(t);
cc=0;
}
}
</script>
</head>

<body>
<table id="tt" width="200" border="1">
<tr>
<td></td>
</tr>
<tr>
<td id="qq">&nbsp;</td>
</tr>
<tr>
<td id="ww">&nbsp;</td>
</tr>
</table>
<button onClick="t=setInterval('tamanno(1)',10)">Aumentar 100px</button>
<button onClick="t=setInterval('tamanno(-1)',10)">Disminuir 100px</button>
</body>
</html>
saludos
__________________
by Capitán Buscapina
.