如何使用JavaScript在不按CTRL键的情况下从列表框中选择多个项目?
<asp:ListBox ID="Satellites" runat="server" AppendDataBoundItem="true" AutoPostBack="true" onchange='GetValueSatellite();' Width="400px" SelectionMode="Multiple"></asp:ListBox>
$('option').mousedown(function (e) {
e.preventDefault();
$(this).prop('selected', $(this).prop('selected') ? false : true);
return false;
});
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.