开发者

To like and share the application when the user clicks on share button in facebook

Hi I am a ruby on rails developer and now working on the f开发者_如何学Pythonacebook. Any one please give a suggestion so that to like and share the application when the user clicks on share button on facebook.


Put this inside of your facebook-SDK:

$(function(){
  $('ID/CLASS OF YOUR BUTTON').click(function(e){
            e.preventDefault();
            FB.ui({
                method: 'feed',
                name: 'NAME YOU WANT',
                link: 'YOUR LINK',
                picture: YOUR URL OF YOUR PICTURE
                caption: 'YOUR CAPTION',
                description: 'YOUR DESCRIPTION',
            });
        });
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜