I have a radioButtonList with two elements in it. A beacon with a value of Yes and a radial button with a value of No.
Below I have a panel that I want to make visible when "Yes" radioButton is selected and hidden when "No" is selected. I initially implemented this using the AutoPostBack attribute, but I want to do this in Javascript so that it does not cause a postback. Here is the code. Any help would be greatly appreciated.
<asp:RadioButtonList ID="rbl1" runat="server" onClick="changed(this);" >
<asp:ListItem Value="Yes">Yes</asp:ListItem>
<asp:ListItem Value="No">No</asp:ListItem>
<asp:Panel ID="panel1" runat="server">
<--other controls here -->
</asp:Panel>
function changed(rbl) {
//not sure what to put in here
}
Thanks in advance,
wants to give Petersburg
source
share