jquery Boxy close popup

I use the rather excellent Boxy plugin to do some modal style popups.

If you want to close the popup programatically from within the popup, say from a cancel button, you can do it like so…

<input type=button value="Cancel" onClick="cancel_button(this);">
function cancel_button(popup){
 if(confirm("All changes will be lost")){
  Boxy.get(popup).hide();
 }
}
  1. Adam Khan says:

    Thanks for this — couldn’t figure out the syntax for how to refer to a Boxy from the Boxy docs.

  2. Adam Khan says:

    Hey, just saw you’re in Brighton as well. Second time that’s happened when searching the worldwide web for little techie things.

  1. There are no trackbacks for this post yet.

Leave a Reply