I’m trying to call a function when a radio button is clicked and I’m not sure why it won’t work.
This works:
<input type="radio" onClick="alert();" />
But this for some reason does not:
<input type="radio" onClick="myFunction();" />
<script language="javascript">
function myFunction(){
alert();
}
</script>
Any help is much appreciated.
It does work, so your problem lies elsewhere, perhaps.