How to access screen resolution information from Facebook Page Tab application (inside iframe)

262 views Asked by At

I got FB application that makes some changes on user uploaded photos and output them as desktop wallpapers. I would like to predefine current user screen resolution but it looks impossible to achieve that from iframe (due to security reasons).

Are there some special tricks you can do inside FB application iframe to get this informations?

1

There are 1 answers

0
TomaszSobczak On BEST ANSWER

Solution is really simple. With new Facebook channelUrl you are gaining access to original screen.width and screen.height properties.

The channel file addresses some issues with cross domain communication in certain browsers.

More to read here