3

Salesforce's "Facebook" auth provider directs a non-logged in user to the page https://www.facebook.com/login.php that is not very mobile friendly. I see no configuration for this page and appending "?display=touch" to the original URL doesn't help.

The aim here is to use Facebook as the authenticator for a mobile HTML5 app hosted on Force.com without the result being ugly.

1

See Login for JavaScript on the Facebook Developer site. Basically, you use their JavaScript library, and call FB.login(callback), which will display one of four different login mechanisms if the user isn't already logged in (mobile HTML, desktop HTML, iOS native, or Android native). Once called, its basically out of your hands until your callback is called, at which point you have a valid session (or an error message).

  • Right now I am doing very little (and therefore can change very little); just leaving the work to the "Auth. Provider". I had a look through the various settings at the Facebook app side and didn't see anything there either. But it does look like (as mentioned in the document you link to) that there is browser detection so hopefully Facebook will "do the right thing" and automatically direct to the mobile version of its login page. – Keith C Dec 4 '13 at 17:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.