Doug T. Doug T. - 16 days ago 10
HTML Question

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">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.

Answer

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.