소셜 플러그인을 사용하여 내 사이트에 버튼을 삽입하고 있습니다. 나는 같은 버튼 문서 (http://developers.facebook.com/docs/reference/plugins/like/)에서 생성 된 코드로 시작했다. 나는 보내기 또는 얼굴없이 표준 레이아웃을 사용하고 있습니다. 단추 자체가 표시되고 제대로 작동합니다. 그러나 주석 대화 상자가 표시되지 않습니다.버튼 주석 대화 상자와 같은 소셜 플러그인이 표시되지 않습니다.
이 작업을 수행하기위한 제안이 많이 있지만 지금까지는 실패했습니다. 폭은 450px입니다. HTML5, XFBML 및 IFrame 버전을 사용해 보았습니다. IFrame 버전에 '덧글 추가'링크가 있습니다. 해당 대화 상자가 표시되었지만 잘림되었습니다. FB.init도 사용했습니다. 여기 내 HTML입니다. 나는 버튼과 비슷한 점을 제외하고는 모든 것을 제거했다. CSS 관련일지도 모른다고 생각했지만, 버려진 버전은 작동하지 않는다.
<!DOCTYPE html>
<html xmlns:fb="http://ogp.me/ns/fb#">
<body>
<div id="fb-root"></div>
<script>
window.fbAsyncInit = function() {
FB.init({
appId : 'appid', // App ID
channelUrl : '//localhost:8282/myapp/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>
<!-- <div class="fb-like" data-href="http://www.espn.com" data-send="false" data-show-faces="false" data-width="450"></div> -->
<fb:like href="http://www.espn.com" send="false" width="450" show_faces="false" />
</body>
</html>
간혹 두 번째 눈 쌍이 필요합니다. 도움에 미리 감사드립니다.