All Scripts JavaScripts ASP Scripts Other Scripts
How to get value from selected radio button
Unfortunately you cannot see at once which radio button in a group is selected. You have to go through all radio buttond and see which one's checked property is true.
|
|
for (i=0;i<document.form1.rbgroup.length;i++)
{
if (document.form1.rbgroup[i].checked)
{
rbgroup_value = document.form1.rbgroup[i].value;
}
} |
|