Closed (fixed)
Project:
Automodal
Version:
6.x-1.0
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
21 Jul 2011 at 04:33 UTC
Updated:
28 Nov 2013 at 11:50 UTC
Jump to comment: Most recent
Hello, I wondered how I could close the modalframe, by just clicking on the area around the modalframe (in other words, by clicking on any spot outside the modalframe).
I googled "jquery and close dialogs" and found this piece of code:
$('.ui-widget-overlay').live('click', function() {
$(".dialogClass").dialog( "close" );
});
I tried to add this to ui.dialogs.js and it didn't work, unfortunately.
How could I close modalframes by clicking outside them?
Comments
Comment #1
thedavidmeister commentedThis works for me
Comment #1.0
thedavidmeister commentededit
Comment #2
dsnopek@thedavidmeister's solution looks good! Add that to your theme or in a custom module.