Jobin Jobin - 4 months ago 7x
jQuery Question

How to handle the close event of Bootstrap popup

In my mvc application I have used one bootstrap popup, I need to check whether any changes are made in textboxes in this popup before closing this window, and give an option to save this before closing. How can I handle the close event of bootstrap popup window?
I have tried

$('#myModal').on('', function () {
// do something…

It will only fire after the close event.


Use the event..

$('#myModal').on('', function (e) {
    //do something..