I use jQueryUI to create a dialog; I want the dialog object to be destroyed when it is deleted.
So, I did something like this:
thisDialog.dialog({
autoOpen: true,
close: function(event, ui) {
thisDialog.dialog("destroy");
}
});
What I want to do is to preserve the existence of the element that this Dialog is attached to, but just destroy the jQueryUI object attached to it .dialog(), not change my DOM. p>
Example:
http://jsfiddle.net/ytWPV/1/
Update:
Could this be a bug / problem with jQueryUI? If someone can show it, I will also agree with him as an answer
source
share