You can temporarily disable the dropdown menu functionality. This is a workaround.
An example with an input field inside a drop-down "menu":
//for dropdown field not closing when clicking on inputfield $(document).on('focus', 'input', function(e) { // this attribute can be anything except "dropdown", you can leave it blank $('#yourDropdownID').attr('data-toggle','off'); }); //for dropdown field back to normal when not on inputfield $(document).on('focusout', 'input', function(e) { $('#yourDropdownID').attr('data-toggle','dropdown'); });
This can be used for everything that can be clicked, and you can individually determine which items are clicked, close or not close the drop-down menu.
Balogh mihály
source share