fancyapps/fancyBox — Issue #129: beforeClose function firing when opening. 
Author: DennisSmolek
Created: 2012-02-01 07:57:12+00:00
State: open

I have a script pulling tons of data via AJAX. I'm having issues with double posting ETC and the easiest thing to do would be to simply reload the page when fancybox is closed.
ANY code I add here gets fired as soon as fancybox is triggered. Also, if I do a alert it fires 4 times.
code:
$(".hidden").fancybox({
beforeClose : function() {
parent.location.reload(true); },
arrows : false,
closeClick : false,
nextClick : false,
maxWidth : 700,
helpers : {
overlay : {closeClick: false}
}

});
//Trigger the FancyBox to launch
$(".hidden").trigger('click');

I even tried attaching a listener to the close X image and it doesnt fire either... Any ideas?