如何从我的网站检查某人是否被喜欢我的粉丝专页? [英] How to check if someone is liked my fanpage from my website?
问题描述
我想检查用户是否喜欢我的粉丝专页,如果他不喜欢,我会跳过此步骤;如果他不喜欢,我想建议他喜欢我的粉丝专页,我不希望这一切都在我的网站上在目标网页上放置目标网页或其他内容.所有这些都在我的网站上,我不想在目标网页上放置目标网页或其他内容. 谢谢
I want to check if a user liked my fan-page from my website and if he did i skip the step and if he didnt i want to suggest him to like my fan-page,its all on my website i dont want to put a landing page or something else on my fan-page.all of it is on my website,i don't want to put a landing page or anything else on my fan-page. Thanks
推荐答案
只有2种方法:
-)使用edge.create事件: https://developers.facebook.com/docs/reference/javascript/FB.Event.subscribe/
缺点:只有在单击网站上的赞"按钮后,才能立即进行检查.因此,如果用户回来,则无法确定是否仍点了赞"按钮.而且,您永远也不会获得用户的ID (已弃用)
downside: this can only check right after clicking a like button on your website. so, if the user comes back, you can´t be sure if the like button is still clicked. also, you never get the id of the user, of course (deprecated)
-)使用Facebook登录名授权>您可以检查用户点赞> user_likes所需的权限.但我怀疑您是否真的想为此授权用户...
-) authorization with facebook login > you can check for the user likes > user_likes permission needed. but i doubt that you really want to authorize the user just for this...
您可以使用的图形api调用:
the graph api call you could use:
me/likes?target_id=[page-id]
订阅: 需要user_subscriptions权限.图形api调用将如下所示:
subscription: permission user_subscriptions needed. graph api call would be the following:
me/subscribedto?user=[user-id]
这篇关于如何从我的网站检查某人是否被喜欢我的粉丝专页?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!