Facebook API - 如何发布/分享大照片

Pau*_*ard 7 photo facebook-graph-api

我已经按照非常明确的教程在fb时间线上发布(分享)一个故事.您可以在FB Share按钮后面的网站上看到我正在使用的代码.如何强制照片变大而不是缩略图?我应该将什么添加到js代码(FB.ui)?一种行为?但是我该怎么写呢?我对FB api很新,所以请用简单的英语...谢谢!保罗

小智 4

我浏览了你的代码。您正在使用饲料方法。

\n\n
FB.ui(\n{\nmethod: 'feed',\nname: 'Paul Godard \xe2\x80\x93 Soul Photography',\nlink: 'http://www.paulgodard.com/',\npicture: 'http://www.gondwanastudio.com/xMedia/Images/Photos/PG_010501-011000/PG_010927.jpg',\nsource: '',\ncaption: 'Paul Godard | Soul Photography | Landscape | Nature | Fine Art',\ndescription: 'I am blessed.  I have 2 wonderful children Enya and James and my best friend is their mother, my soulmate for many years.  I live in a wonderful home in Africa, the wildest continent of the world.  I am very privileged and grateful.  There is so much beauty around us but people dont see it anymore...',\nmessage: ''\n});\n
Run Code Online (Sandbox Code Playgroud)\n\n

安装完毕后,尝试使用照片方法如下

\n\n
FB.api('me/photos', 'post', {\n                        message: 'your message',\n                        status: 'success',\n                        access_token: access_token,\n                        url: 'your_Img_url'\n                    }, function(response) {\n                    });\n
Run Code Online (Sandbox Code Playgroud)\n\n

在这里我们上传一张照片。它将被保存在一个新相册中,因为我们没有在上面的代码中创建任何内容,并且一张大照片将被张贴在您的墙上。

\n

  • 但是我们如何实现像点击帖子下面的“分享”按钮一样的分享功能呢?我发现单击此按钮时,我的时间轴有一个共享帖子,但图像未保存到我的相册中(我更喜欢) (2认同)