FB.login—same app ID with multiple domains

So, we're looking to start using FB.login for our sites instead of the full page redirect because it looks better. But, there's one problem. We currently use domain aliases to handle the multiple domain/single app id problem. That is, when a user is logging in on www.domain.com we transparently add a suffix during the FB auth handshake (e.g., www.domain.com.master.com). It works well for this use case, but it doesn't seem possible to do something similar with FB.login. Has anyone done something similar to get FB.login working with multiple domains using a single app id?

Thanks!

Answers


You should specify all domains in "App Domain" field in application "Basic Settings" this will allow you transparent usage of Facebook JavaScript SDK to authorize your users.


Note that you can specify multiple subdomains but they can only belong to one domain. That's because it must match the URL in the Website with Facebook Login > Site URL.

This is a problem for me when I'm developing Facebook apps with multiple feed dialogs needing redirect URLs to different domains.


We were using same app ID for a web based game which was accessible via facebook canvas and simple fb.login too - like you can go on website and login using your website username and password Or you can login using facebook username password (f connect)Or you can access our app in canvas as facebook application.

Facebook sent us an email informing that this isn't allowed - using same app iD to access single app with various methods. We had to change the app ID. Now it's working fine.

I hope the helps in one way or other and is related to the original query.


Need Your Help

Type hinting in PHP constructors?

php class oop constructor

Is there anything to stop me from type hinting like this within the __construct() parentheses?

How to flatten Tree in Scala?

scala tree functional-programming

It is pretty easy to write flatten(lol: List[List[T]]): List[T] which transforms a list of lists to a new list. Other "flat" collections (e.g. Set) seem to provide flatten too.