Reputation: 571
I have the following example http://jsfiddle.net/zidski/Mz9QU/1/
If you click on Link2 and then Link1 I want Link2 box to close.
Can anyone help?
Upvotes: 0
Views: 98
Reputation: 9253
The fix just involves calling your close_model()
function before the show_modal()
function to close any other open modals before opening the new one :)
Upvotes: 3
Reputation: 4931
Why not just call close_modal();
as soon as any modal box is opened? This would hide any open dialog/modal boxes whether they're open or not but would create minimal overhead (probably less than putting a check to see if any are open).
Upvotes: 1