diff --git a/js/jquery.mobile.simpledialog2.js b/js/jquery.mobile.simpledialog2.js index 743a93f..7b3c77d 100644 --- a/js/jquery.mobile.simpledialog2.js +++ b/js/jquery.mobile.simpledialog2.js @@ -75,6 +75,7 @@ if ( typeof $.mobile.sdLastInput !== 'undefined' ) { delete $.mobile.sdLastInput; } self.internalID = initDate.getTime(); self.displayAnchor = $.mobile.activePage.children('.ui-content').first(); + if ( self.displayAnchor.length === 0 ) { self.displayAnchor = $.mobile.activePage; } self.dialogPage = $("
"); self.sdAllContent = self.dialogPage.find('[data-role=content]');