Opened 12 years ago

Closed 12 years ago

Last modified 10 years ago

#5887 closed bug (notabug)

Dialog: Removing existing dialog data on init

Reported by: rozwell Owned by:
Priority: minor Milestone:
Component: ui.dialog Version: 1.8.2
Keywords: remove, existing, dialog, box, init, hidden, data Cc:
Blocked by: Blocking:


If you init dialog, it will add it's hidden box at the end of documents body. What is ok, it's supposed to act like this.

But if you do this on ajax based site, it will keep adding new boxes over and over again on every (for example) tab change. And with tab change I mean calling some function (like $.ajax) to reload some part of a page. This will cause displaying different hidden box on every dialog('open') call.

Hidden dialog box (for specific id) should be removed on every init to avoid situation described above.

If it breaks some assumptions, I suggest adding a boolean option to clear already existing hidden data.

Change History (3)

comment:1 Changed 12 years ago by Scott González

Resolution: invalid
Status: newclosed

You need to either manually destroy the dialog yourself, or move it back to the original location on close. We're going to add an appendTo option to change where the dialog is placed in a future version.

comment:2 Changed 12 years ago by rozwell

Thank you for your reply, appendTo will do the job better ;)

comment:3 Changed 10 years ago by Scott González

Milestone: TBD

Milestone TBD deleted

Note: See TracTickets for help on using tickets.