简体   繁体   中英

enable_profile_selector for FB.Login() is not working

I am trying to use Facebook login(javascript sdk of facebook) in my HTML page. I am able to get it to work. However, I need to provide the user the option to choose his/her profiles for my application(website) so that my application can post to the user's facebook pages(the ones that has been enabled for posting). Below is my code, please advise what I am missing.

<a class="btn" onclick="FB.login(function(response) {
   statusChangeCallback(response);
 },  {
    scope: 'publish_actions,publish_pages,manage_pages', 
    return_scopes: true,
    enable_profile_selector: true,
    profile_selector_ids: '1X86XXXXXXX3,250XXXXXXXXXX14'
});"><i class="icon-plus"></i>Add Facebook Account</a>

Also, I understand that the option profile_selector_ids is not mandatory as by default it should show all profiles for the user.

Appreciate your help in advance!

Thanks & Best Regards, Anand Patil

请尝试使用以下范围manage_pages,publish_stream,publish_actions

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM