- Overview
- Documents
Dropdowns is a simple jQuery plugin that make it easier to create awesome Bootstrap style dropdowns (menus, selects, panels, tooltips etc) with additional
-
sex shop
sex shop
sex shop
sex shop
sex shop
seks shop
spanish fly
psikolog
sohbet numara
sohbet hatti
Source: labs.abeautifulsite.net
1. INCLUDE CSS AND JS FILES
<link type="text/css" rel="stylesheet" href="jquery.dropdown.css" /> <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js"></script> <script type="text/javascript" src="jquery.dropdown.js"></script>
2. HTML
Create a dropdown by placing a div with a unique id and the dropdown class immediately before your closing body tag.
For dropdown menus, the div should contain a ul with the dropdown-menu class:
<div id="dropdown-1" class="dropdown dropdown-tip"> <ul class="dropdown-menu"> <li><a href="#1">Item 1</a></li> <li><a href="#2">Item 2</a></li> <li><a href="#3">Item 3</a></li> <li class="dropdown-divider"></li> <li><a href="#4">Item 4</a></li> <li><a href="#5">Item 5</a></li> <li><a href="#5">Item 6</a></li> </ul> </div>
For dropdown panels, the div should contain a div with the dropdown-panel class:
<div id="dropdown-1" class="dropdown dropdown-tip"> <div class="dropdown-panel"> You can put whatever HTML you want in a panel! </div> </div>
Add the data-dropdown attribute to any HTML element, using the id of the dropdown as the value. That’s all you have to do–you don’t even have to initialize it! The plugin also works on dynamically generated triggers.
<a href="#" data-dropdown="#dropdown-1">dropdown</a>
3. API
You probably won’t need these, but they’re there just in case:
- attach – attach a dropdown to the selected trigger element(s); pass in the #dropdown-id as value
- detach – detach a dropdown from the selected trigger element(s)
- enable – enables the dropdown and removes the dropdown-disabled class from the trigger
- disable – disables the dropdown and adds the dropdown-disabled class to the trigger
- hide – hide the dropdown
- show – show the dropdown
Example usage: $('#trigger').dropdown('method', [value]);
4. EVENTS
You can attach events to each dropdown:
- show — triggered when the dropdown is shown
- hide — triggered when the dropdown is hidden
Example usage:
$('#dropdown-id').on('show', function(event, dropdownData) { console.log(dropdownData); }).on('hide', function(event, dropdownData) { console.log(dropdownData); });