This is in my routes
Route::get('auth/facebook', 'Front@redirectToProvider');
Front.php
public function redirectToProvider()
{
return Socialite::driver('facebook')->redirect();
}
But in permission window i don't see permission for phone number . how to add that perission?
Laravel Framework version 5.2.45
Update : It seems i can't get the phone number but it seems i can get date of birth .My idea was that if i know how to get phone then i can use the same code to get other fields too like email and date of birth . What do i need to add and where to get these fields?
It is not possible to get the phone number of a Facebook User. There is not even a field for it in the user table: https://developers.facebook.com/docs/graph-api/reference/user
About birthday and other fields, see this thread: How to get birthday gender and religion information using laravel socialite implementing facebook Api
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.