开发者

Facebook extended permissions dialog disappears

I'm trying a couple of different ways to show the "publish_stream" extended permissions dialog. Each time I see a blank dialog with title "Request for Special Permissions" show up for a brief few seconds then disappear. I'm doing some very straight-forward stuff:

<script>
    Facebook.showPermissionDialog('publish_stream');
</script>

I also see the problem with clicking

<fb:prompt-permission perms="publish_stream"&开发者_开发百科gt;Grant Permission</fb:prompt_permission>

Both have the same problem. I have tried this out on Firefox (under Ubuntu and Windows) and Internet Explorer.

Am I going nuts? Is there something I need to change about my Facebook application (in terms of settings) to get this to work?

Another note: If I do "showPermissionsDialog" with another permission, say "offline_access" it works. Other Facebook dialogs also work. It seems to be localized to the publish_stream extended permission.


If you are talking about Facebook Connect, make sure that you have specified the correct XML namespace in the main html tag as suggested by Facebook.

Also there should be a Facebook loader JavaScript file below the body tag.

And finally there should be the xd_receiver file specified at the bottom of your page.


FIXED!

The problem is... I'm an idiot.

The dialog shows this behavior if the user has previously granted this permission. That's why it worked for some permissions, and not for others (that must have been granted through other means). When I revoke the publish_stream permissions for that user, it works.

Moral of the story is don't show that JavaScript call unless you know the user doesn't have that permission.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜