jquery select2 - not working

后端 未结 6 830
春和景丽
春和景丽 2020-12-15 05:41

I am using select2 plugin(ivaynberg.github.io/select2). I am trying to display a dropdown(select). It is getting all the items in data.php as options. However select2 is mea

6条回答
  •  长情又很酷
    2020-12-15 06:14

    I guess user2315153 wants to receive multiple remote values, and incorrectly assigning select2() with ajax call to a <select> element.

    The correct way to get remote values, is using a normal <input> element, and if is desired multiple values, inform the "multiple" parameter on method call. Example:

    
    
    

提交回复
热议问题