I am having a really difficult time getting the Facebook login feature to work once I import into Intel XDK.
I know I have seen others saying they have it working so I must be missing something. Hopefully someone will be kind enough to point out what I need to do differently.
My goal is ultimately to have the player be able to sign in with their FB account and I will personalize the game with their name, scores, etc.
I have tested with Cranberry's FB 2.x and PB plugins and ended up running into the same issues.
Here is what I tested:
- In C2, build titleLayout w/ titleEvents
- Add a sprite for the button as btnSprite
- Add the C2 Facebook Object
- Enter my Facebook Developer App ID and Secret
- In the titleEvents add Event for Touch on btnSprite with Facebook Log In action
Browser in PC, Android and iOS
- In C2, Export HTML5
- In Filezilla, upload exported files to server
- In browser, test live page
- Login successful
Android App Emulate
- In C2, export Cordova specific to Android
- In Intel XDK, import Android files exported in C2 to create a new project as a Hybrid app
- Check the box for Facebook Connect then enter applicable App ID and App Name
- I have also tested without checking the Facebook Connect with the same results
- Go to Emulate
- Click the btnSprite
- Nothing happens
I have essentially done the same thing using Intel XDK Test and Build for Android and iOS, various versions and hardware devices. All have resulted in the btnSprite doing nothing.
The one thing I have been unsure of is the App Name. I assume this is the "Display Name" in the FB Developer account under Settings. I have the main app and the test app. I expect as long as the "Display Name" and the App Id are from the same app it should be fine.
I also found that I didn't have the toggle for "Do you want to make this app...general public?" under "Status & Review" set to "Yes" so I fixed that. It appears to apply to the whole app including any test apps within it.
This has been making me nuts.
I am considering trying to use the HTML_iFrame plugin to pass the FB information and sign in back and forth but am really hoping to get the proper Log In to work.
Any help would be greatly appreciated.