JavaScript: client side event on RadioButtonList

Posted by Unknown On Thursday, July 16, 2015 0 comments
ASP.NET Code

       <asp:RadioButtonList runat="server" ID="radReportType" onchange="displayReportType();" RepeatDirection="Horizontal">
           <asp:ListItem Text="Shipment" Value="Fruit" Selected="True">
           <asp:ListItem Text="Customer" Value="Vegetable">
           <asp:ListItem Text="Carrier" Value="Meat">
       </asp:RadioButtonList>

jQuery

   var radio = $("[id*=radFruits] input:checked");
   var value = radio.val();

0 comments:

Post a Comment