search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

Intercept Modal close/hide

Asked by Daniel
5 years ago.

Hi!
I use the Modal popup. I want to intercept the closing/hiding of the modal. I want to ask the User if he saved everything - after that the modal can be closed. If the user clicks "no" the modal should stay opened.

Thanks!
DAniel

Comment posted by Daniel
5 years ago.

Solution: around Line 189 in daypilot2.1.js:

window.setTimeout(function() {

This.hideDiv.onclick = function() {
if(confirm("QUESTION?"))
This.hide();
};

}, 500);

This question is more than 3 months old and has been closed. Please create a new question if you have anything to add.