【问题标题】:Facebook Send method fetching wrong content?Facebook Send 方法获取错误的内容?
【发布时间】:2013-11-18 05:21:58
【问题描述】:

我正在使用 facebook 发送方法在我的网站中邀请朋友。

这是代码

function FacebookInviteFriends()
  {
    FB.ui({
      method: 'send',
      name: 'Join Stuffuneed',
      picture: '<?php echo $this->getSkinUrl('images/owl_logo_250_250.jpg') ?>',
      link: '<?php echo $customerLink?>',
      description: "You have been invited to join Stuffuneed. Stuffuneed is the place to find the stuff you always needed but didn't know where to find",
    });
  }

它显示了这个对话框

问题是这样的 它没有显示确切的名称。图片,链接说明。

我也使用了 og 元标记

<meta property="og:title" content="Join Stuffuneed" />
<meta property="og:image" content="http://www.stuffuneed.com/stuffuneed/skin/frontend/default/lockrez/images/owl_logo_25_250.jpg"/>
<meta property="og:site_name" content="Stuffuneed"/>
<meta property="og:url" content="http://www.stuffuneed.com/stuffuneed/"/>
<meta property="og:type" content="website"/>

但它仍然向我显示错误的内容 请帮助我...

【问题讨论】:

  • 图片/链接是否托管在任何实时服务器上?还是在本地主机上?

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


【解决方案1】:

description picture 不是 发送 对话框中的有效参数。 Reference

您只需提供链接; fb 将自行获取图像。也许您可以在您提供的链接中设置og:image 的元标记。

【讨论】:

  • 我也使用了 og 元标签 stuffuneed.com/stuffuneed/skin/frontend/default/lockrez/images/…> stuffuneed.com/stuffuneed/"> 但仍然显示错误内容
  • Facebook 能识别你的元标签吗? developers.facebook.com/tools/debug
  • 是的,但有时它让我无法从 URL 检索数据。我的网址是:stuffuneed.com/stuffuneed
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2013-03-02
  • 2017-08-15
  • 2016-03-04
  • 2022-11-09
相关资源
最近更新 更多