Some pits of jquery dialog

Source: Internet
Author: User

The jquery dialog tool makes it easy to generate a popup box, but there are some bugs in some scenarios that require multiple pop-up boxes

Specific scenarios:

When a modal box is used once, a modal frame that has disappeared is removed when another modal frame is used.

After troubleshooting: This is due to the first time when the modal box is closed, jquery will be added to the body at the end of a div,display:none, not visible, the next call when the direct fetch, (the main function is to save the modal box location parameter)

However, when a different modal box is awakened, the existing invisible div will be awakened except for a new modal box div

Complete by defining the modal box cancellation action:

$ ("Body div"). Last (). Parent (). Parent (). remove ();

Some pits of jquery dialog

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.