Prevent pop-ups from being blocked

前端 未结 5 1095

I am using a Facebook login method in my code on page load, but when I execute this code, the pop-up blocker closes the Facebook permission window.

How can I open th

5条回答
  •  清歌不尽
    2020-12-05 06:29

    This is specifically denied in the documentation:

    "You should only call this on a user event as it opens a popup. Most browsers block popups, unless they were initiated from a user event, such as a click on a button or a link."

    It's also simply poor UX.

提交回复
热议问题