Quote:
Originally Posted by Old Pedant
Ummm...but you *ASKED* for
And that's not as simple.
A normal radio button, if there is only ONE of the given name=, can *NOT* be unchecked. Only checked.
You would need some mildly sneaky JavaScript code to be able to un-check a single radio button.
I don't think that's what you really wanted, based on your last post, but just be aware of it.
|
I badly explained, re ask my question

So my function day contains the document.getElementById (*day that i have selected from menù select*) and if select radio female button, add 40 at number that i selected from menù, else if I have selected male write only the number that I take from menù

I would like this method
Code:
<script>
function day (myDay)
{
Now write that I think :)
if (id = "male" == checked false)
{
var number;
number = myDay + 40;
}
else (id = "male" == checked true)
{
var number;
number = myDay;
}
alert (myDay);
}
</script>
<body>
<input type = "radio" name = "sex" id = "male" checked = "false" />
<input type = "radio" name = "sex" id = "female" checked = "true" />
Day: <select id = "myDay">
<option>1</option>
<option>2</option>
</select>