Member
296 Points
940 Posts
Jul 05, 2019 11:31 AM|shahid.majeed|LINK
Hi,
I am trying to loop through my select list to store keys and values. But i want to select the selectlist with class selector instead of id selector.
<asp:ListBox ID="listOfOpenBills" runat="server" Width="95%" Height="100px" CssClass="openBill"></asp:ListBox> function loadKeys() { var Keys = []; var Values = []; $.each($("#<% = listOfOpenBills.ClientID %> option"), function (index, item) { Keys.push(item.value); Values.push(item.innerHTML); }); }
Member
296 Points
940 Posts
Jquery class selector instead of id selector for select option
Jul 05, 2019 11:31 AM|shahid.majeed|LINK
Hi,
I am trying to loop through my select list to store keys and values. But i want to select the selectlist with class selector instead of id selector.