javascript - Select2 How to control srollbar in select2-4.0.2 version for too long data -


i have 1 question need how control srollbar in select2-4.0.2 version long data .

my requirement : when option tags exceed 5 option , need display vertical scrollbar dropdown windows similar size attribute under select tag ( ) , requirement how set option in select2 ?

for example :

<option value="al">alabama</option> <option value="ak">alaska</option> <option value="az">arizona</option> <option value="ar">arkansas</option> <option value="ca">california</option> <option value="co">colorado</option> <option value="ct">connecticut</option> <option value="de">delaware</option> <option value="fl">florida</option> <option value="ga">georgia</option> <option value="hi">hawaii</option> <option value="id">idaho</option> </select>  <script> $('.select2').css('width','200px').select2({allowclear:true}) </script> 

br kai


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

.htaccess - ERR_TOO_MANY_REDIRECTS htaccess -