hi all i am binding my dropdown with Jquery-Select2. Its working fine but now i need to Bind my Multi-Value selectBox by using Jquery-Select2.
M
So I take it you want 2 options default selected, and then get the value of it? If so:
http://jsfiddle.net/NdQbw/1/
And to get value:
alert($(".leaderMultiSelctdropdown").val());
To set the value:
$(".leaderMultiSelctdropdown").val(["a", "c"]);
You can also use an array to set the values:
var selectedValues = new Array();
selectedValues[0] = "a";
selectedValues[1] = "c";
$(".Books_Illustrations").val(selectedValues);
http://jsfiddle.net/NdQbw/4/