SHARE
TWEET

FB setSize

a guest May 9th, 2011 291 Never
  1. <html>
  2. <head>
  3. </head>
  4. <body>
  5. <div id="fb-root"></div>
  6. <script>
  7. window.fbAsyncInit = function() {
  8.         FB.init({appId: 'your app id', status: true, cookie: true,
  9.                          xfbml: true});
  10.         FB.Canvas.setSize();
  11. };
  12.  
  13. function sizeChangeCallback() {
  14.         FB.Canvas.setSize();
  15. }
  16. (function() {
  17. var e = document.createElement('script'); e.async = true;
  18. e.src = document.location.protocol +
  19.   '//connect.facebook.net/en_US/all.js';
  20. document.getElementById('fb-root').appendChild(e);
  21. }());
  22. </script>
  23. </body>
  24. </html>
RAW Paste Data
Top