I've got this -
$(function(){
var dialogOpts = {
autoOpen: true,
height: 400,
width: 600,
position: ["center", "center"],
modal: true,
closeOnEscape: true,
};
$("#contact").dialog(dialogOpts);
$("#why").dialog(dialogOpts);
});
The two dialog boxes each produce their own ui-widget-overlay so the transparent background is getting mounted up into a murky mess. Anyone know how I can restrict it so there's only ever one present regardless of how many dialogs are open?
Also, is there a way to click on the modal background to close the open dialogs as well as the close button and escape key?
Any advice appreciated!