popSelect
1.1、popSelect简介

popSelect是一个jQuery界面插件。

popSelect官网:http://jquer.in/popSelect

1.2、下载popSelect

通过bower下载:

bower install --save popSelect
1.3、引入popSelect
<link href="/bower_components/popSelect/dist/jquery.popSelect.min.css" rel="stylesheet">

<script src="/bower_components/jquery/jquery.min.js"></script>
<script src="/bower_components/popSelect/dist/jquery.popSelect.min.js"></script>
1.4、使用popSelect

html代码:

<select id="select" multiple>
  <option value="game-of-thrones">Game Of Thrones</option>
  <option value="prison-break">Prison Break</option>
  <option value="lost">Lost</option>
  <option value="sherlock-holmes" selected="selected">Sherlock Holmes</option>
  <option value="true-detectives" selected="selected">True Detectives</option>
</select>

js代码:

$('#example2').popSelect({
    showTitle: false,
    placeholderText: 'Click to Add More',
    position: 'bottom',
    maxAllowed: 3
});