FB.login dialog does not close on Google Chrome FB.login dialog does not close on Google Chrome google-chrome google-chrome

FB.login dialog does not close on Google Chrome


I got a similar call to FB.login() to close the dialog box by changing

onclick="dologin()"

to

onclick="dologin(); return false;"


Given the age of this post, I am guessing that the poster has solved this; however, given that this is also a resource for others searching to resolve similar issues, I thought that I would include my experience just in case.

I found out that what was causing this same issue symptom for me was accidentally forgetting to include event.preventDefault(); in my "click" listener handler in jQuery. The facebook login dialog was popping up and allowing me to log in but not disappearing. The issue was that the website was performing the default form post action, which was interfering with the facebook call-back function.


I had the same exact problem. I did two things, first I added this line right before the FB.init() call:

FB.Flash.hasMinVersion = function () { return false; };

Then I went into the FB app page and added the Site Domain (i.e. test.com).

I think the site domain setting was the key, but I am not 100% positive. All I know is that it seems to always close now in all browsers including Chrome.