Tema: type ratio
Ver Mensaje Individual
  #1 (permalink)  
Antiguo 07/03/2007, 07:07
sermondi
 
Fecha de Ingreso: marzo-2007
Mensajes: 10
Antigüedad: 18 años
Puntos: 0
type ratio

Buenas,
tengo el siguiente código:
<td width="109">
<div align="center"><strong>SI</strong>
<input name="matriculado" type="radio" value=1>
</div></td>
<td width="115">

<div align="center"><strong>NO</strong>
<input name="matriculado" type="radio" checked value=0>
</div></td>

y desde javascript quiero que cuando esté marcado el SI haga una cosa y cuando esté marcado el NO haga otra.

El codigo en javascript que uso es este:
if ((document.alumno.matriculado.value == 1) && ((anio.length != 0)|| (mes.length != 0)||(dia.length != 0))){
alert("Debes introducir la fecha de matriculación.");
document.alumno.anio.focus();
return 0;
}

pero no funciona.
El error que me da es:
alert(document.alumno.matriculado.value) ---> undefined

Podeis ayudarme ... muchas gracias.