Facebook Like button for one facebook page of an app from it's own ios app

后端 未结 2 1489
迷失自我
迷失自我 2021-01-07 08:47

I am looking for Like Button to be shown in my ios native app, users of that app have already connected to app via facebook account.

there are several questions rela

2条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-07 09:20

    It appears that Liking a page on behalf of a user is still impossible. I've glanced over the iOS SDK Reference, and it doesn't seem like there is a built in mechanism to like anything.

    However, in reading one of the other posts you linked to, and remembering that Facebook opened up the Like open graph action so app developers could allow their users to like content generated by their application...I found this link about built-in-actions (likes).

    According to that link, you can post Like actions to your users by POSTing to https://graph.facebook.com//og.likes with the POST params for object (the open graph object URL you want to like on behalf of the user in this case your page's url. eg. www.facebook.com/yourpage) and access_token (obviously, for your user).

    I'm not totally convinced that will work; though it is conceivable. My second thought would be to create an Open Graph Object for your page, and have all your users like that. Though, that is a little less ideal, as it removes the possibility of people finding your Page while they're on Facebook and would require you to put a lot more effort into getting likes for the Page via your website, application, etc.

    I hope that helps a bit, good luck.

提交回复
热议问题