Skip to content

Instantly share code, notes, and snippets.

@tcelestino
Created September 4, 2012 00:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tcelestino/3615147 to your computer and use it in GitHub Desktop.
Save tcelestino/3615147 to your computer and use it in GitHub Desktop.
Permissions app on page tab facebook onload
var scope = ['user_about_me', 'user_groups', 'user_likes', 'user_photos', 'publish_stream', 'read_friendlists'];
var oauth_url = 'https://www.facebook.com/dialog/oauth/';
oauth_url += '?client_id=<?php echo $fb->getAppID() ?>';
oauth_url += '&redirect_uri=' + encodeURIComponent('https://www.facebook.com/pages/null/Página-de-Teste/503673046324840/?sk=app_<?php echo $fb->getAppID() ?>');
oauth_url += '&scope='+scope;
window.top.location = oauth_url;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment