I need to keep the modal from being closed by the user

169 views Asked by At

Any Ideas?

I tried inserting ....({ .....,...., close:false,....}) and nothing.

Thanks in advance.

PS: I will close the modal window when satisfied with $.modal.close();

1

There are 1 answers

2
Eric Martin On

If you call a modal window as you have indicated {close:false}, the following will happen:

  • The closeHTML will not be displayed
  • The user cannot click the overlay to close the dialog
  • The user cannot press ESC to close the dialog

If you have a button/link in your code with the simplemodal-close class, the user will still be able to press that to close the dialog.

So, based on the information you have provided, if you are using {close:false}, the only other way possible for a user to close the dialog is if you have provided a way for them to. As such, you need to hide, disable, or remove the simplemodal-close class until you are ready for them to close the dialog.