Close Window button within HTML in floatbox

Page: 1

Author Post
Member
Registered: Apr 2012
Posts: 3
Administrator
Registered: Aug 2008
Posts: 3066
Ordinarily, it would be quite simple to close the floatbox simply by calling the parent.fb.end() function. However, you're out of luck in your particular case because the donation form in the floatbox is a cross-domain iframe. It is running under https, as it should, while the originating page is running under http. Because the protocols are different, cross-domain scripting prevention is in effect and the two pages cannot exchange any javascript instructions. You cannot close a cross-domain iframed floatbox from a script or action that occurs inside the iframe page.

In the case of your donation page, I think if you need the ability to call parent.fb.end() then you will need to run the parent page as https as well. But if the donation page comes from a different site anyway, (i.e., is served from a different domain name), then it's going to be cross-domain anyway, regardless of protocol, and you remain out of luck.
« Last edit by admin on Sat Apr 14, 2012 10:52 am. »

Page: 1