Facebook Graph Api v2.10使用带有大缩略图的标题或共享的Feed的变通方法

时间:2017-09-09 22:51:09

标签: javascript facebook facebook-graph-api fb.ui

我想让用户从我的网站分享图片。我希望它是使用fb.ui共享选项的更大的缩略图,代码波纹管工作,但它将我的大图像减少到更小。

分享代码:

FB.ui({
        method: 'share_open_graph',
        action_type: 'og.shares',
        action_properties: JSON.stringify({
            object : {
              // 'og:url': 'url', // your url to share
               'og:title': 'Here my custom title',
               'og:description': 'here custom description',
               'og:image': 'image_url'

            }
        })
        })

以上代码的结果: result

我可以使用Feed选项发布首选大小的图像,代码和结果如下。但问题是我无法添加标题或消息等附加信息。

 FB.ui({
         method: 'feed',
    name: 'name',
    picture: 'image_url',
    caption: 'caption',
    description: 'description',
    message: 'message'
    });

我知道对于Feed选项不推荐使用消息,标题和说明,并且大缩略图暂时不适用于共享选项。如果有人有这方面的解决方案,或知道一些解决方法让我知道。

因此,我需要解决方案,在帖子中获取更大的缩略图,尺寸为图像......或者使用Feed图像发布一些其他信息。

0 个答案:

没有答案