ブログ

Facebookページの縦スクロールバー

Facebookページ内welcomeページの縦スクロールバーを消すのに、「FB.Canvas.setAutoResize」と言うのを使っていたのですが、実は2012年1月1日でサポートが終わっていたのですね。
割と最近まで表示されていたのでうっかり調査不足でした。
そして、縦スクロールバーがしっかり表示されてるし。

setAutoResize() → setAutoGrow()

に変更する事で表示されました。

以下サンプルコード


<div id="fb-root"></div>
<script type="text/javascript">
(function() {
    var d = document;
    var e = d.createElement("script"); e.async = true;
    e.src = d.location.protocol + "//connect.facebook.net/ja_JP/all.js";
    d.getElementById('fb-root').appendChild(e);
}());
window.fbAsyncInit = function() {
     FB.init({
        appId: '',
        status: true,
        cookie: true
    });
    FB.Canvas.setAutoGrow({ width: , height:  });
};
</script>

書き換えたら、縦スクロールバーは消えました。
Facebookは本当に仕様変更が多いので、注意ですねぇ・・・。

コメント

コメントを残す

メールアドレスが公開されることはありません。

*
To prove you're a person (not a spam script), type the security text shown in the picture. Click here to regenerate some new text.
Click to hear an audio file of the anti-spam word

日本語が含まれない投稿は無視されますのでご注意ください。(スパム対策)

  

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

お仕事のご依頼はこちら

ただ今の作業状況

現在の作業状況
現在、新規受注を停止しております。
 
 


PAGE TOP