0

我在这里有我的链接:

<a name="fb_share" type="icon_link" share_url="" href="">
    <button class="btn btn-large btn-primary tasto" disabled="disabled">Condividi contenuto</button>
</a>

我的JS在这里:

FB.api('/217822418323942',
function(response){
        $('.step_4').children('a').attr('href', 'http://www.facebook.com/sharer.php?u='+response.link+'&t=CONDIVIDI!');
});

但是 Chrome 给了我这个错误:

Refused to display document because display forbidden by X-Frame-Options.

它没有分享...解决方案?

4

1 回答 1

0

已解决,facebook 不再使用共享器,正确的代码是:

FB.ui({
    method: 'feed',
    name: response.from.name,
     link: response.link,
     picture: 'http://images.sodahead.com/polls/002641083/3649326924_lol_guy_answer_1_xlarge.jpeg',
     caption: 'LOL.',
     description: 'meme'
},
function(response) {
    if (response && response.post_id) {
        console.log('Post was published.');
        } else {
            console.log('Post was not published.');
        }
});
于 2012-08-06T11:15:46.187 回答