Close dialog on click (anywhere)

前端 未结 10 1166
旧时难觅i
旧时难觅i 2020-11-30 23:34

Is there a default option to close a jQuery dialog by clicking somewhere on the screen instead of the close icon?

10条回答
  •  清歌不尽
    2020-12-01 00:19

    This post may help:

    http://www.jensbits.com/2010/06/16/jquery-modal-dialog-close-on-overlay-click/

    See also How to close a jQuery UI modal dialog by clicking outside the area covered by the box? for explanation of when and how to apply overlay click or live event depending on how you are using dialog on page.

提交回复
热议问题