Quantcast
Channel: jQuery remove options from select - Stack Overflow
Viewing all articles
Browse latest Browse all 14

Answer by Vishav Premlall for jQuery remove options from select

$
0
0

When I did just a remove the option remained in the ddl on the view, but was gone in the html (if u inspect the page)

$("#ddlSelectList option[value='2']").remove(); //removes the option with value = 2$('#ddlSelectList').val('').trigger('chosen:updated'); //refreshes the drop down list

Viewing all articles
Browse latest Browse all 14

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>