I have problem. I've made ajax json multiple tags with select2 it works great, but problem stars when i try to edit and insert selected early values like this:
<select id="select2" name="field">
<option value="1" selected>title 1</option>
<option value="2" selected>title 2</option>
</select>
It seems like Select2 doesn't recognized that value must be value, and title should show as tag.
My js code that i use for get json:
I was trying to give data: json_data but without results. How to reload Select2 to show title but not id ?