jQuery multiselect drop down menu

后端 未结 9 1308
眼角桃花
眼角桃花 2020-11-28 07:30

I have a simple html multi select drop down list:


                        
    
提交评论

  • 2020-11-28 08:08

    I was also looking for a simple multi select for my company. I wanted something simple, highly customizable and with no big dependencies others than jQuery.

    I didn't found one fitting my needs so I decided to code my own.
    I use it in production.

    Here's some demos and documentation: loudev.com

    If you want to contribute, check the github repository

    0 讨论(0)
  • 2020-11-28 08:08
    <select id="mycontrolId" multiple="multiple">
       <option value="1" >one</option>
       <option value="2" >two</option>
       <option value="3">three</option>
       <option value="4">four</option>
    </select>
    
    var data = "1,3,4"; var dataarray = data.split(",");
    
    $("#mycontrolId").val(dataarray);
    
    0 讨论(0)
  • 提交回复
    热议问题