I want to change modal behavior after a specific event.
$('.myModal').modal('show'); // default behavior - user can close modal on ESC $(button).click(function(){ $('.myModal').modal({keyboard:false}); // override // prevous line code does not work as i expect, // user can close modal with ESC $('.myModal').data('modal').option.keyboard = false; // even this code doesn't work });
Any help would be appreciated
I had the same problem, I used the wrong data ...
You can try with this (considering bt3):
$('#myModal').data('bs.modal').options.keyboard=false;
But
This does not work if the modal is open, you need to update it.
Source: https://habr.com/ru/post/1415152/More articles:How to remove soft buttons / menus in an android ice cream sandwich? - androidhttps://translate.googleusercontent.com/translate_c?depth=1&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1415148/how-to-deny-pushes-to-master-branch-that-has-not-yet-been-approved-in-phabricator&usg=ALkJrhiXaJ9R0L_qNnNkVhp_Idl88zewQgDifferent screen orientations - androidReleasing all keys after disabling the keyboard in X11 / Linux using xinput? - linuxEntity Framework POCO T4 sometimes creates an EntityCollection and sometimes creates a FixUpCollection - entity-framework-4Replace html tags with javascript - javascriptAccess SSAS Using an External User Database - authenticationhttps://translate.googleusercontent.com/translate_c?depth=1&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1415155/auto-save-outlook-emails-to-folder-using-c&usg=ALkJrhiZW1xura_phFS1IUG9oC_XP96Y-QInternalsVisibleTo, Signing and Unit tests, how to make it practical? - c #Objective-C: AudioOutputUnitStart is time consuming. Possible workaround? - objective-cAll Articles