开发者

Facebook API Authentication

开发者 https://www.devze.com 2023-01-30 01:02 出处:网络
if I want to authenticate a user through facebook is it necessary to开发者_StackOverflow社区 get an \'offline_access\' permission for my application.

if I want to authenticate a user through facebook is it necessary to开发者_StackOverflow社区 get an 'offline_access' permission for my application.

It should be possible for the user to link his application profile to his facebook account. So if he is already logged in to facebook he didn't has to authenticate again in my application.

I'm using the PHP-SDK with Zend.

Thank you.

- lony


The php-sdk facebook class has a method - getLoginUrl.

You can pass an array to it, change the array params based on what permissions you need.

getLoginUrl(array(
                    'req_perms' => 'publish_stream,offline_access'));

A detailed list of permissions can be found here -

http://developers.facebook.com/docs/reference/api/user


Generally you only need the offline_access permission if you intend to access that user's account when they are not using your application. For example, your application has some back-end process running which posts to their wall once a week.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号