the problem I'm facing is pretty much as the title describes it. I'm using Facebook auth (using the JavaScript SDK) so users can login to my app and it was working ok with Chrome UNTIL Chrome version 59 (the latest one).
Before Chrome 59 (58, 57, ...) when the user tries to login, the Facebook popup opens and the request for the Facebook credentials is made. But, in Chrome 59 instead of a popup, a new tab is opened. The problem is that this tab isn't in focus and the user don't see that it was opened, or sometimes it is opened and is infinitely loading.
Is someone else facing this problem? If so, are there any workarounds?
Thanks!
SOLVED
As commented by Raul Mangolin, this issue was already solved by Faceebook.
Chrome 59 seems to handle location=yes
in window.open
now differently. I assume this is a bug, because Chrome shows the location bar anyway and I can't find a change log entry about this.
So if you have any influence on how the popup is opened, then change it to location=no
as a workaround for now.
// Opens as new tab in Chrome 59
// Older versions and all other browsers open it as popup
window.open("https://www.facebook.com","","location=yes")
// Opens as popup also in Chrome 59
// Chrome, Firefox and Edge show location bar regardless; IE shows URL in title
window.open("https://www.facebook.com","","location=no")
Test it yourself: http://output.jsbin.com/hikeleyiwe
As Raul Mangolin pointed out, Facebook is aware of this issue: https://developers.facebook.com/bugs/470345923308265/
In Chrome 59 it will open new tab instead of a popup window if the "location"
or the "toolbar"
is set to "yes"
.
Just set them to "no"
, like this:
"location=no, toolbar=no"
There's also a simpler solution - just don't include these statements at all and then popup will open instead of a new tab.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With