jquery boxy plugin: prevent multiple instances of the same dialog when clicking the link multiple ti
- by Lyon
Hi,
I'm using the Boxy jQuery plugin to open dialog windows and populating it through ajax.
http://onehackoranother.com/projects/jquery/boxy/
Here's my code so far:
$("a.create").click(function (e) {
url = $(e.target).attr('href');
Boxy.load(url, {title:'Test'});
});
This opens up a dialog alright. However, if I click the link again, another dialog will open. How can I make it such that the previously opened Boxy dialog will come into focus? I only want one instance of this dialog.
I tried assigning a variable to var ele = Boxy.load(); but the variable ele returns undefined...
Alas, I can't make out much from the limited Boxy documentation available.
Enabling the option modal: true would prevent the user from clicking on the link multiple times, but I don't want the overlay to show.
Thanks for any light you can shed on this.
-Lyon