I think I saw a post similar to the issue I’m having, but a little bit different.
For this reason, I’m posting again.
So, I have this filter select here (only where it says “LastName”, the other is the bug I’m having I will describe below):
I applied here the select2 in the first (where it says “LastName”). and it works fine, it opens and everything works okay.
But, my plan is to allow the person to add more filters as they wish.
For that, I replace the innerhtml of the div with a copy of the 3 selects.
Something like the code in the jsfiddle below.
Doing this works great, and then I apply the select2 only for that part only (for example, the first 3 selects have the class .select-multiple_1 on the class. This “copy” has the .select-multiple_2 on the class. (image above, line below the “LastName”).
It looks good. But, if I try to change the first filters (where it says “LastName”), it doesn’t work.
Any reason for that? I have some code on jsfiddle but it’s not working there. If it helps. Edit fiddle - JSFiddle - Code Playground
Thank you very much.