It becomes annoying. when I click on an item in the Bootstrap drop-down list, the dropdown does not close. I installed it to open the Facebox lightbox when you click the drop-down list, but there is a problem with it.

What i tried
When the item is clicked, I tried to do this:
$('.dropdown.open').removeClass('open'); $('.dropdown-menu').hide();
This hides it, but for some reason it will not open again.
As you can see, I really need the dropdown to close because it looks crap when it remains open (mainly because the z-index dropdown is higher than the overlay of the Facebox modal window.
Why I do not use the built-in modal block Bootstrap
If you're wondering why I donβt use the beautiful modal framework built into Bootstrap, this is because:
- It has no way to load content into it using AJAX.
- You must type HTML every time for modal; with Facebox, you can do simple:
$.facebox({ajax:'/assets/ajax/dialogs/dialog?type=block-user&id=1234567'}); - It uses CSS3 animations to animate (which looks very nice), but in browsers other than CSS3, it just shows that it doesn't look so good; Facebox uses JavaScript to fade out, so it works in all browsers.
jquery twitter-bootstrap
Nathan Jun 08 2018-12-12T00: 00Z
source share