
08/07/2005, 01:26
|
 | Moderador extraterrestre | | Fecha de Ingreso: diciembre-2001 Ubicación: Madrid
Mensajes: 6.987
Antigüedad: 23 años, 2 meses Puntos: 61 | |
Pues he hecho un ejemplillo con tu script y funciona perfectamente en el Zorrillo Rojo... Código PHP: <html>
<head>
<script type="text/javascript" language="JavaScript">
function borrar(i){
if (document.getElementById('check' + i).checked == false) {
window.document.getElementById('total' + i).value = '' ;
window.document.getElementById('cant' + i).value = '';
}
else{
window.document.getElementById('cant' + i).focus();
}
}
</script>
<style>
*{font:normal 10px/10px verdana;}
</style>
<title></title>
</head>
<body>
<input checked="checked"
type="checkbox"
name="check1"
id="check1"
value="1"
onclick="borrar(1)" /> Lo compro<br />
300 x <input type="text"
size="5"
name="cant1"
id="cant1"
onkeyup="document.getElementById('total1').value = 300 * this.value;" /> = <input type="text" readonly="readonly" name="total1" id="total1" />
</body>
</html>
Lo tienes igual?
__________________ Cómo escribir
No hay pregunta tonta, sino tonto que quiere seguir en la ignorancia. |