I have a Facebook app with 10 test users. I am developing an iOS app and have setup up the plist file with the Facebook app id as described in the docs.
I run my app in iOS Simulator and click my Facebook Login button which takes me to the Facebook web app. I try to login with one of my Facebook app's test user and I get the error below.
I've seen Facebook Developer videos where the presenter logs on to the Facebook web app from the iOS Simulator. Do you know why I can't?
Thanks
I got it working by using Reset Content and Settings on the simulator and restarting it.
When it wasn't working I noticed that when I went to facebook.com in the simulator the email address was always pre-populated with my test user. I wonder if the simulator has some aggressive caching, or mobile safari itself.
I suspect that shutting down the safari app would have done the trick too.
Related
I am developing an ios app and trying to allow the user to connect to their LinkedIn account.
I am using the steps found in
https://developer.linkedin.com/docs/ios-sdk-auth
where I
Registered my app with LinkedIn to get the application id.
Updated my info.plist with the *li{application id}* entries for URL Schemes
Called LISDKSessionManager.createSessionWithAuth() to start the login process.
However, this only opens up the LinkedIn app on my iPad, but does not show me which permission I had requested nor redirect me back to my app. I am at a loss to if this is the intended behaviour or am I missing a step.
Note that the sampleapp provided by linkedin also does not show me the page with a list of permissions requested or redirect me back to my own app.
It appears that the LinkedIn app has an iPad-specific bug that prevents it from returning to other apps after createSessionWithAuth: is called, even when all credentials are correct.
(I had to wait for the delivery of a physical iPhone to test my hypothesis, as there is no way to log in like this on a simulator).
Update
My answer was with regard to the 1.0.2 sdk, which also had problems with all iOS 9 devices. The iOS 9 problems were fixed with the 1.0.4 sdk, but the iPad problems remain.
Found the solution. For me, it was about setting our bundles right:
On https://www.linkedin.com/developer/apps/xxxxxx/mobile, make sure that your 'iOS Bundle Identifiers' is the same on your app. Plus, click on Update! I just added and 'forgot' to save them.
After I compiled my game in Unity and XCode, I'm running the game on my iPhone. And when FB.Login("email,publish_actions", LoginCallback) gets called, it brings me to a window that says
Error
App not Setup: The developers of this app have not set up this app properly for Facebook Login.
In the App Dashboard Do you want to make this app and all its live features available to the general public? is set to NO, HOWEVER I've added a Test User in the App Dashboard, and I'm logged in as that Test User on my phone outside of my app under Settings. Shouldn't this work? I don't want to publish my app to all users just yet.
I also double checked:
"App Id" in Unity -> Facebook -> Edit Settings is the same as the one in the App Dashboard
"Bundle ID" in the App Dashboard is the same as in Unity's Player Settings -> Bundle Identifier
In the App Dashboard I have "App Domain" empty, since I just run it from the iPhone and not from the Web. Or do I still need an App Domain..?
Not sure if it's relevant, but on running FB.Init, he logs this in XCode:
Using SDK 4.3.6, Build 131121.17562b74012d24a
Finished loading Facebook dll. Build N/A
DO you have Facebook APP id in info.plist? check bundle id is case sensitive? Is single sign on set to yes in Facebook dashboard? also try enabling client auth login and embedded browser auth login in FB dashboard.
I found the problem. Everything was set up correctly with the app on Facebook and Unity, however just on my phone my Facebook app had another user logged in.
Seems like that is a different login thing that when you log in under Settings.
Thanks for your help though!
I've recently added Facebook Single Sign On within my application using Appcelerator' Titanium. Which is working nicely but is failing to redirect back to my application automatically when presented with the "Already Authorized" facebook page.
If the user clicks the "Okay" button within facebook the Application re-opens and works as per usual. I'm just looking to get rid of that extra step for users.
Any suggestions? I've come across Objective C solutions such as : Does the Facebook iOS SDK require the user to authenticate every time they use the app?
Cheers,
Tom
I believe the issue was related to the Facebook App not being setup properly and not directly testing on a device instead of the simulator.
The following settings should be applied within you Facebook Application.
Enable : Native iOS App
iOS Bundle ID: com.yourcompany.yourapp
iPhone App Store ID: 24242423
Configured for iOS SSO: Enabled
Testing on the simulator will trigger Safari to open and show the Authorization dialog due to the Facebook App not being installed (hence why you need a real device). Pushing your app to the device and triggering the SSO within your application will then redirect back to your application if an error, already authorized or success occurs.
Hope this helps anyone that's had this occur.
I have seen an iPhone app Path and Installed in Device and in this app I have seen Facebook functionality means I have installed Facebook App and successfully logged in this app and now How can I open my profile,feeds,friend list and other functionality from my demo app so please give me idea how can I develop this functionality.
Any application can register a custom URL scheme, and when your app opens that URL, IOS will switch to the application that has registered that URL scheme. The Facebook app has registered such a scheme, with apparently quite some capabilities. See wiki.akosma.com.
However, I don't think that you can switch back to your app after that. So, if you just want to fetch some Facebook information, then you are probably better off using the Facebook web interfaces. You don't need to have the Facebook app installed at all when doing that.
I'm trying to integrate facebook in my iOS 5 application.
As mentioned in facebook documentation, i'm doing everything as they mentioned.
Usually when facebook is initiated to authorize, it will take the user to browser opening facebook website and asks to authenticate. but in my case, it opens browser and immediately it goes back to the app. I didn't understand what's happening.
Here's the video of the issue that I'm facing
I noticed that if the facebook app is installed on iphone, above mentioned problem is noticed
Is your app ID on your project .plist?
Look at "Modify the app property list file" on the Facebook iOS tutorial