i have button, if press button open bootstrap-select list show has, aside, 2 buttons, 1 save changes , 1 cancel modifications. pressing of buttons make bootstrap-select hide not need bootstrap-select drop-down button anymore.
on website have several bootstrap-select lists must hide drop-down button 1 list, guess have add class, how add class (or remove) drop-down button 1 bootstrap-select list (only button, not whole list)?
http://silviomoreto.github.io/bootstrap-select/
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-select/1.6.3/js/bootstrap-select.min.js"></script> <link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-select/1.6.3/css/bootstrap-select.min.css" rel="stylesheet"/> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script> <link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css" rel="stylesheet"/> <select class="selectpicker bootstrap-select-with-dropdown-button"> <option>mustard</option> <option>ketchup</option> <option>relish</option> </select> <select class="selectpicker bootstrap-select-without-dropdown-button"> <option>mustard</option> <option>ketchup</option> <option>relish</option> </select>
you can adding class selectpicker element:
$('.your-selectpicker-nobutton').selectpicker('setstyle', 'remove-button-class', 'add'); then, on css, hide dropdown caret:
.remove-button-class .caret { display: none; } check style method here: http://silviomoreto.github.io/bootstrap-select/#methods
Comments
Post a Comment