OK, so I have a canvas iframe application with its height set to "Installable" using javascrip sdk calls to facebook in FB.Canvas.setSize (); and FB.Canvas.setAutoGrow () ;. They work just fine since the iframe is set to a specific pixel height based on its contents.
The problem is that when I call Fancybox, it positions itself based on that height. I know that it is exactly what it should do, since fancybox jQuery returns a viewport:
(line 673 of the latest version of jquery.fancybox-1.3.4.js):
_get_viewport = function() {
return [
$(window).width() - (currentOpts.margin * 2),
$(window).height() - (currentOpts.margin * 2),
$(document).scrollTop() + currentOpts.margin
];
},
But the problem is that iframes will be longer for many viewers than their browser window. Thus, Fancybox focuses itself in the iframe and ends only partially visible to most viewers. (i.e., the iframe is 1,058 pixels high, and the users browser is only 650 pixels high).
Is there a way for fancybox to simply calculate the physical height of the browser? Or do I need to change some settings in my Facebook canvas app to make it work?
I love the way the only scrollbar is on Facebook (parent if you want).
All offers GREAT appreciated!
source
share