Possible Duplicate:
Facebook Graph API, how to get users email?
Well, in my application, I ask the user to grant permission for me to get his email ... let's say that he does ...
According to the code of API reference, the FB.getLoginStatus
function returns a Json Object with the following contents:
{
status: 'connected',
authResponse: {
accessToken: '...',
expiresIn:'...',
signedRequest:'...',
userID:'...'
}
}
So, assuming the user has accepted the terms, and granted permission for email to my app, where is the email value? It's in a new child in the FB.getLoginStatus
response? Something like:
{
status: 'connected',
authResponse: {
accessToken: '...',
expiresIn:'...',
signedRequest:'...',
userID:'...'
userEmail:'....'
}
}
In PHP, I use something like that:
json_decode(file_get_contents('http://graph.facebook.com/SOMEIDHERE'))->name;
(a resquest to graph.facebook.com, for example)
But it's not what i'm looking for.
Thanks for your attention.