通过 Facebook 为物品投票,比如?

发布于 2024-10-20 17:13:12 字数 625 浏览 0 评论 0原文

我有一个朋友想举办每周一次的竞赛,用户可以对他们最喜欢的图片进行投票。他希望用户“喜欢”一张照片才能投票。这是该行动的合理机制吗?这行得通吗?有没有合理的方法可以从 Facebook 获取投票数?

Facebook 表示按钮上的点赞数是以下各项的总和:

* The number of likes of this URL
* The number of shares of this URL (this includes copy/pasting a link back to Facebook)
* The number of likes and comments on stories on Facebook about this URL
* The number of inbox messages containing this URL as an attachment.

I'我想确保人们只能投票一次,而不是为了获得选票而将 URL 发送给很多朋友。

与构建更传统的投票系统相比,以这种方式构建它有哪些缺点和/或影响?

谢谢!

I have a friend who wants to run a weekly contest where users can vote on their favorite pictures. He wants users to "Like" a photo in order to vote for it. Is this a reasonable mechanism for this action? Will this work? Is there a reasonable way to get the vote numbers out of facebook?

Facebook indicates that the Like number on a button is the sum of:

* The number of likes of this URL
* The number of shares of this URL (this includes copy/pasting a link back to Facebook)
* The number of likes and comments on stories on Facebook about this URL
* The number of inbox messages containing this URL as an attachment.

I'd want to make sure that people would only be able to vote once, and not message the URL to a lot of friends in order to gain votes.

What are the downsides and/or implications of building it this way versus building a more traditional polling system?

Thanks!

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

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

发布评论

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

评论(2

大海や 2024-10-27 17:13:12

更新:
根据新的促销指南,您不能使用 Like 插件作为投票机制:

您不得使用 Facebook 的特性或功能,例如“点赞”
按钮,作为促销的投票机制。


实际上,使用 Facebook 作为投票系统根本不是一个坏主意,我正在考虑自己实现一个测试投票系统(基于 Facebook Like PLugin 等)。

该方法与此处的答案类似。
您捕获“喜欢”和“不喜欢”:

FB.Event.subscribe('edge.create', function(response) {
    $.ajax({
        type: 'POST',
        url:'/voting.php',
        data: {vote: 'up'}
    });
});
FB.Event.subscribe('edge.remove', function(response) {
    $.ajax({
        type: 'POST',
        url:'/voting.php',
        data: {vote: 'down'}
    });
});

您设置了正确的开放图元标签:

<meta property="og:title" content="Picture Title" />
<meta property="og:type" content="website" />
<meta property="og:url" content="http://domain.com/path/to/picture/page/" />
<meta property="og:image" content="http://domain.com/path/to/picture.jpg" />
<meta property="og:site_name" content="Site Name" />
<meta property="fb:admins" content="XXXXXXX" />
<meta property="fb:app_id" content="XXXXXXX" />

因此,现在您可以执行以下两件事之一:

  1. 在您的数据库中拥有记录您可以根据 JS 事件增加喜欢(或在用户改变主意和不喜欢时减少)
  2. 可能使用 FQL (link_stat 更具体的表格)来收集total_count 对于某个 URL(对象)并检查最喜欢的。

因此,如果您只想从页面内收集投票(喜欢),请根据您的需求使用上面的 FB.events 或 FQL。

UPDATE:
Based on the new Promotions Guidelines, you cannot use the Like plugin as a voting mechanism:

You must not use Facebook features or functionality, such as the Like
button, as a voting mechanism for a promotion.


Actually using Facebook as a Voting-System won't be a bad idea at all, I'm thinking of implementing a test voting-system myself (based on Facebook Like PLugin..etc).

The approach would be similar to the answer here.
You capture the "likes" and "dislikes":

FB.Event.subscribe('edge.create', function(response) {
    $.ajax({
        type: 'POST',
        url:'/voting.php',
        data: {vote: 'up'}
    });
});
FB.Event.subscribe('edge.remove', function(response) {
    $.ajax({
        type: 'POST',
        url:'/voting.php',
        data: {vote: 'down'}
    });
});

You set the correct Open Graph Meta Tags:

<meta property="og:title" content="Picture Title" />
<meta property="og:type" content="website" />
<meta property="og:url" content="http://domain.com/path/to/picture/page/" />
<meta property="og:image" content="http://domain.com/path/to/picture.jpg" />
<meta property="og:site_name" content="Site Name" />
<meta property="fb:admins" content="XXXXXXX" />
<meta property="fb:app_id" content="XXXXXXX" />

So now you can do one of two things:

  1. Have a record in YOUR DB that you increment the likes (or decrement when a user change his mind and dislike) based on the JS events
  2. You may use FQL (link_stat table to be more specific) to collect the total_count for a certain URL (object) and check for the most liked.

So depending on your needs if you only want to collect votes (likes) from within your page use the FB.events above or the FQL otherwise.

故笙诉离歌 2024-10-27 17:13:12

我不相信 Facebook 提供任何相互排斥的“喜欢”方法,因此用户似乎很容易“喜欢”民意调查中的两个(或全部)选项,这会在一定程度上扭曲结果。另外,我不确定一个系统有多可靠,可以将有关产品的讨论混为一谈(“Facebook 上有关此 URL 的故事的点赞和评论数量”和“包含此 URL 作为附件的收件箱消息数量”) ”)作为产品的实际认可。

就我个人而言,我使用 Facebook 消息传递以及电子邮件来分享供应商和广告的恐怖故事,几乎就像分享积极的经历一样。

对我来说,这似乎是一个非常糟糕的选择。如果要使用 Facebook,为什么不简单地在 Facebook 上创建一个民意调查呢?

I don't believe Facebook offers any method of mutually-exclusive 'likes,' so it seems easy for a user to 'like' both (or all) options in the poll, which would skew the results somewhat. Plus I'm not sure how reliable a system it would be to, conflate the discussion about a product ("The number of likes and comments on stories on Facebook about this URL" and "The number of inbox messages containing this URL as an attachment") as an actual endorsement of a product.

Personally, I use Facebook messaging, as well as my email, to share horror-stories of vendors and adverts almost as much as I share the positive experiences with the same.

This seems, to me, to be a very bad choice. If Facebook is to be used, why not simply create a poll thereon?

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