如何实现属于两个不同应用程序的插件的 XFBML 版本,即使用两个不同的应用程序 ID:?

发布于 2025-01-06 22:45:17 字数 388 浏览 2 评论 0原文

到目前为止,我在我的网站上对 Facebook 点赞和评论插件使用了不同的实现:首先使用 iframe 实现点赞插件,然后使用 XFBML 和 Facebook SDK 实现评论插件。

当我实现 Facebook 评论插件时,我需要一个应用程序来管理评论。该网站已经添加了一个应用程序,但我想要一个应用程序只是为了审核评论,所以我仅出于此目的创建了一个新应用程序。

我现在想用 XFBML 替换 Like 插件的 iframe 实现。

问题 1:是否可以有两个不同的应用程序 ID:一个用于评论插件,另一个用于 Facebook SDK 中定义的类似插件?

问题 2:如果不可能使用两个不同的应用程序 ID:,我如何将来自 Like 插件和 facebook 评论插件的数据收集到我的应用程序之一?

I have until now used different implementations for my Facebook like and comment plugins on my site: the like plugin was implemented first, using an iframe and the comment plugin was implemented later, using XFBML and the Facebook SDK.

When I implemented the Facebook comments plugin, I needed an app in order to moderate the comments. The site already add an app, but I wanted to have an app just to moderate the comments, so I created a new one for that purspose only.

I would now like to replace the Like plugin's iframe implementation with an XFBML one.

Question 1: Is it possible to have two different app ID:s, one for the comments plugin and the other for the like plugin defined in the Facebook SDK?

Question 2: If not possible use two different app ID:s, how can I gather the data from both the like plugin and the facebook comments plugin into one of my apps?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

信愁 2025-01-13 22:45:17

一页上不可能有多个应用程序初始化。即使您尝试将应用程序作为参数添加到 JS-SDK 中,也可能会导致意外行为。

为什么收集数据是可能的,您将无法在不同对象之间传输数据。只要 URL 保持不变,就不需要这样做,点赞和评论与 URL 相关,而不是与应用程序相关。

只需继续使用一个应用程序,并按原样保留“点赞”按钮和“评论”社交插件的 URL。

注意:我不确定评论审核工具的行为,因此在最终切换到单个应用程序之前,您可能需要尝试是否能够管理所需应用程序中的评论。如果您无法管理用于点赞的应用程序中的评论,您可以使用已经可用于评论审核的应用程序。

It is not possible to have more than one application initializations on one page. Even if you try to add application as parameter to JS-SDK it may lead to unexpected behavior.

Whyle gathering data is possible you will not be able to transfer data between different Objects. Tis isn't really needed as long as URL remains the same, likes and comments are tied to URL, not an application.

Just continue to use one application and leave URLs for Like Button and Comments social plugins as is.

Note: I'm not sure about behavior of comments moderation tool, so you may want to try if you able to manage comments from the application you want before final switch to single application. If you not able to manage comments from application used for likes you may use one that already works for comments moderation.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文