Simple jQuery animated searchable select menu based on bootstrap framework.
Add [bootmenu.min.js] to your project.
<script src='bootmenu.min.js'></script>
$("div").bootmenu({ parameters });
<div id="selectMenu"></div>
<div id="selectMenu2"></div>
$("#selectMenu").bootmenu({
callback: function(value1) {
alert(value1);
$("#selectMenu2").bootmenu({
listName: "MenuTwo",
callback: function(value2) {
alert(value2);
}
});
}
});
itemsArray of items to be added to the list. (default: Please add items to the dropdown!)
var food = new Array('Pizza', 'Meat', 'Melon', 'Chicken', "Lasagna", "Eggs");
$("#selectMenu").bootmenu({ items : food });
defaultTextThe default placeholder text to display. (default: Select here!)
$("#selectMenu").bootmenu({ defaultText : "Choose your preferences" });
listnameA unique identifier for each select menu, if you’re using more than one menu. (default: listOne)
$("#selectMenu").bootmenu({ listname : "secondmenu" });
background and hoverColorThe background color of menu and the hover color of the items. (default: #3498DB and #2C3E50)
$("#selectMenu").bootmenu({ background : "#000", hoverColor: "#fff" });
listAnimationThe animation effect when clicking the select menu. (default: slideDown)<br>
Available animations: rotation, slideDown, fade, slideLeft, rotate, fly,
$("#selectMenu").bootmenu({ listAnimation : "rotation" });
animationDurationDuration of the animation when clicking the menu. (default: 500ms)
$("#selectMenu").bootmenu({ listAnimation : "fly", animationDuration: 1000 });
$("#selectMenu").bootmenu({
callback: function(selectedValue)
{
// do something
}
});
Bootmenu © 2016-2017.
GitHub @mariomed7at ·
Facebook Mario Medhat