Facebook iframe issues

Out of context: Reply #12

  • Started
  • Last post
  • 13 Responses
  • elahon0

    This is my magic combination that I use, works to remove scroll bars and fixes the height so if your content is longer than the right sidebar, it extends with no problem:

    <body style="overflow: hidden"><!-- WHEN DEVELOPING A LONG PAGE, REMOVE THIS STYLE CLASS. PUT IT BACK IN BEFORE YOU PUBLISH -->

    <div id="container">
    <!-- PUT DIV AND JS CODE HERE FOR IFRAME HEIGHT FIX -->
    <div id="fb-root"></div>
    <script type="text/javascript">
    window.fbAsyncInit = function() {
    FB.init({appId: 'XXXXXXXXXXXXXXXXX', status: true, cookie: true, xfbml: true});
    window.setTimeout(function() {
    FB.Canvas.setAutoResize();
    }, 250);
    };
    (function() {
    var e = document.createElement('script... e.async = true;
    e.src = document.location.protocol +
    '//connect.facebook.net/en_US/al...
    document.getElementById('fb-root...
    }());
    </script>
    <div id="content">
    MY FACEBOOK IFRAME CODE STARTS HERE............

View thread