My Setup:
I've got a node form where I've applied an automodal class to the delete button (to show the delete confirmation form in a modal) and on that same page I'm using jQuery UI to show a "Save" dialog in the same style modal (but it's not an actual "automodal" window.) Basically I have two jQuery dialogs on the same page, one is created through automodal, the other is javascript.
The Issue:
The first time each modal is triggered everything is fine, but soon the content, titles and other variables start getting messed up. For example, the dialog title for the delete modal is permanent. Once it's triggered, that is the title for all modal windows. I believe the cause is that automodal is confused by the presence of a pre-existing dialog in the DOM.
Has this happened to anyone else?
I've circumvented the issue by using dialog('destroy') on my non-automodal dialogs so that the dom is cleared each time a dialog is closed, but then I have to re-initialize the dialog every time it's triggered which isn't the jQuery UI recommended way of doing things.
Comments
Comment #1
dsnopekThe automodal code is pretty simple - I don't see anything that could cause this. If there is a bug, it might be in Modalframe.