Reputation: 47
How can I access the array to fetch the email address? I tried something like "$userInfo->['email'];
$userInfo = $facebook -> api("/$user"); print_r($userInfo);
Output:
Array (
[id] => 1790302499
[name] => Lorem Ipsum
[first_name] => Lorem
[last_name] => Ipsum
[link] => http://www.facebook.com/Lorem.Ipsum
[username] => Lorem.Ipsum
[birthday] => 11/11/1991
[location] => Array (
[id] => 114304221920174
)
[work] => Array (
[0] => Array (
[employer] => Array (
[id] => 114304221920174
[name] => Google.com
)
[start_date] => 0000-00
)
)
[gender] => male
[email] => [email protected]
[verified] => 1
)
Thank you in advance !!
Upvotes: 0
Views: 210