I have a very simple javascript function, it should pop up an alert when a radio button is clicked. If I click the no radio button it works, but if I click yes I get the syntax error unexpected token ')' and I cannot see why.
Code:
<script>
function check(val) {
if (val == "Yes"){
alert("Yes")
}else{
alert("No")
}
}
</script>
Aucun commentaire:
Enregistrer un commentaire