views:

1106

answers:

2

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 IE

Am I going nuts? Is there something I need to change about my facebook app (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. Seems to be localized to the publish_stream extended permission.

A: 

If you are talking about FB connect, make sure that you have specified the correct xml namespace in main html tag as suggested by fb.

Also there should be facebook loader javascript file below the body tag.

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

Sarfraz
unfortunately this isn't fb connect.
Doug T.
+1  A: 

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.

Doug T.