Javascript

Fermé
petite.maria Messages postés 1 Date d'inscription dimanche 6 décembre 2009 Statut Membre Dernière intervention 7 décembre 2009 - 7 déc. 2009 à 16:54
Bonjour,
je veux savoir la correction de cet exemple
******************************

<html>
<head>
<script>
function verifier()

{
if (document.forms[0].element[0].r[0].checked==true) &&
(document.forms[0].element[0].r[2].checked==true)

alert('movese chois')
else

alert('bonne chois')
}

</script>
</head>

<body>
<form>

choisire un numero <br>
<input type="radio" name=chois" value="1">20<br>
<input type="radio" name=chois" value="2">25<br>
<input type="radio" name=chois" value="3"> 30 <br>

<input type=button value="verifier" onClick="verifier()">

</form>



</body>
</html>