we built a facebook application with ruby/rails and facebooker (iframe application) and are currently stuck with the FB.Canvas.setAutoResize which seems to fail in some cases. using the example from facebook developer docs ( see http://developers.facebook.com/docs/reference/javascript/ ). the autoresize fails once you enter a page which is higher than 800px - so to say, it just works as long as the canvas gets bigger, not when it gets smaller. anyone has a clue or maybe a workaround?
here is the resizing code piece
<div id="fb-root" style="width:1px;height:1px;position:absolute;"></div>
<script type="text/javascript">
window.fbAsyncInit = function() {
FB.init({appId: '126342024064822', status: true, cookie: true, xfbml: true});
FB.Canvas.setAutoResize(true,100);
};
(function() {
var e = document.createElement('script'); e.async = true;
e.src = document.location.protocol +
'//connect.facebook.net/en_US/all.js';
document.getElementById('fb-root').appendChild(e);
}());
</script>
i am very thankful for any comments or hints, since i am twisting my head around this one for more than a day now.