SyntaxFix
Write A Post
Hire A Developer
Questions
Actually, you have to explicitly compare it to true. If the dialog doesn't exist yet, it will not return false (as you would expect), it will return a DOM object.
if ($('#mydialog').dialog('isOpen') === true) { // true } else { // false }