views:

53

answers:

1

Hi, I am working on an iframe based Facebook applicaton. I am able to use FB.Canvas.setAutoResize(); to let the iframe "stretch" the page so there's no scroll bar for the iframe. The page may be 2-3 page-length in height. I can scroll down the page using the windows scroll bar. The issue is when I am at the bottom of the page and I click a link inside the frame, the content in the frame loads but I am still at the bottom of the page. Is there a way to set it so that when the link inside the frame is clicked, the outer page will scroll back up to the top of the page so you can see the content of the frame at the top? Mike

A: 

Within the iframe, window.scrollTo(0, 0); should scroll it to the top.

idealmachine
Hi, I have tried it but it didn't work for me. I am thinking maybe it's a cross domain issue? Our app is inside the frame of apps.facebook.com?
bobojam
Hi, looks like this has been an issue for a while and devs are still waiting for Facebook to provide the solution which they had in their old API. The issue is tracked here http://github.com/facebook/connect-js/issues#issue/135
bobojam
This is crazy! Facebook has not released a fix yet!
Pierre Valade