私たちのサイトで XFBML フォームをレンダリングするために javascript SDK を使用しようとしています。
の登録フォームを読み込めません。以前に Facebook でこのアプリをブロックした可能性があります。このアプリのブロックを解除するには、Facebook のプライバシー設定に移動してください。(エラー: 'client_id' が無効です。)
私のアプリは登録され、正しいIDで登録されています。
コードは次のようになります。
<script>
window.fbAsyncInit = function() {
FB.init({
appId : '118446328234891', // App ID
channelUrl : '//www.sakshum.org/channel.html', // Channel File
status : true, // check login status
cookie : true, // enable cookies to allow the server to access the session
xfbml : true // parse XFBML
});
// Additional initialization code here
};
// Load the SDK Asynchronously
(function(d){
var js, id = 'facebook-jssdk', ref = d.getElementsByTagName('script')[0];
if (d.getElementById(id)) {return;}
js = d.createElement('script'); js.id = id; js.async = true;
js.src = "//connect.facebook.net/en_US/all.js";
ref.parentNode.insertBefore(js, ref);
}(document));
</script>
<script src="https://connect.facebook.net/en_US/all.js#appId=118446328234891&xfbml=1"></script>
<fb:registration fields="name,birthday,gender,location,email" redirect-uri="http%3A%2F%2Fwww.sakshum.org%2FFbValidation" width="530">
</fb:registration>
iframeだけを使用して非xfbmlバージョンを使用する場合に追加するだけで、すべて正常に動作します。