Facebook Login & Settings

Joined
Oct 18, 2011
Messages
160
Reaction score
0
Points
16
Hi,

I am integrating Facebook login within a small app.

When the user logs in with Facebook, we need to pull their:
- name
- latest 3 profile photos
- email address

One of the other developers who is working on the project too, has stated that it is only possible to pull the 3 profile photos IF the user's Facebook privacy account settings are set to completely open.

Can anyone confirm if this is true. I understand that Tinder pulls your Facebook photos quite easily, so i don't believe this is true? Thank you.
 
Joined
May 19, 2009
Messages
8,428
Reaction score
295
Points
83
Location
Waiting for a mate . . .
Your Mac's Specs
21" iMac 2.9Ghz 16GB RAM - 10.11.3, iPhone6s & iPad Air 2 - iOS 9.2.1, ATV 4Th Gen tvOS, ATV3
Whats the code you're using ??

Swift or Obj-C

Well I did find this on Stack Overflow

You need to make request to graph api that will return you JSON in response to your request. For example if you want to get name, profile picture (it will give you url for profile picture) and id you can make request in your viewDidLoad() as follows

Code:
FBRequestConnection.startWithGraphPath("me?fields=id,name,picture", completionHandler: {(connection: FBRequestConnection!, result: AnyObject!, error: NSError!) -> Void in
        if (result? != nil) {
            NSLog("error = \(error)")

            println(result)
        }
        } as FBRequestHandler)
 
Last edited:

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top