1<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
2<script src="https://cdn.rawgit.com/harvesthq/chosen/gh-pages/chosen.jquery.min.js"></script>
3<link href="https://cdn.rawgit.com/harvesthq/chosen/gh-pages/chosen.min.css" rel="stylesheet"/>
4
5<form action="http://httpbin.org/post" method="post">
6 <select data-placeholder="Begin typing a name to filter..." multiple class="chosen-select" name="test">
7 <option value=""></option>
8 <option>American Black Bear</option>
9 <option>Asiatic Black Bear</option>
10 <option>Brown Bear</option>
11 <option>Giant Panda</option>
12 <option>Sloth Bear</option>
13 <option>Sun Bear</option>
14 <option>Polar Bear</option>
15 <option>Spectacled Bear</option>
16 </select>
17 <input type="submit">
18</form>
1<!-- JUST ADD multiple ATTRIBUTE WITHIN select ATTRIBUTE -->
2Cars:<br>
3<select name="car" multiple>
4 <option value="Volvo">Volvo</option>
5 <option value="Thar">Thar</option>
6 <option value="Audi">Audi</option>
7</select>
1//Installation
2<link href="https://cdn.jsdelivr.net/npm/select2@4.1.0-beta.1/dist/css/select2.min.css" rel="stylesheet" />
3<script src="https://cdn.jsdelivr.net/npm/select2@4.1.0-beta.1/dist/js/select2.min.js"></script>
4
5
6
7// In your Javascript (external .js resource or <script> tag)
8$(document).ready(function() {
9 $('.js-example-basic-single').select2();
10});