Get Account User Id FBML
I'm new to the faceboo开发者_如何学Ck app making and I'm just wondering how I can get the user who enabled the app (the one using it)'s user id.
Thanks
Like this:
$facebook = new Facebook('API', 'SECRET');
echo $facebook->user;
The new PHP SDK is available here: http://github.com/facebook/php-sdk. It has an example that shows how to get the user id and profile: http://github.com/facebook/php-sdk/blob/master/examples/example.php.
精彩评论