showing results for - "select2 tags set value jquery"
Noemi
23 Nov 2018
1<select id="lang" >
2   <option value="1">php</option>
3   <option value="2">asp</option>
4   <option value="3">java</option>
5</select>
6
7<script>
8	$("#lang").select2().select2('val','1');
9</script>
Isabel
02 Sep 2017
1$('#mySelect').select2({
2  data: ['one','two'],
3  tags: true
4});
5$('#mySelect').val(['one','two']).trigger('change')
similar questions
queries leading to this page
select2 tags set value jquery