Basic Google Sign-In for Websites code not working in Internet Explorer 11

后端 未结 4 1852
终归单人心
终归单人心 2020-12-05 05:36

I am attempting to use Google Sign-In for Websites (https://developers.google.com/identity/sign-in/web/) and noticed that my solution is not working in Internet Explorer 11.

4条回答
  •  半阙折子戏
    2020-12-05 05:58

    Be sure that you don't have IE 11 configured to block all third party cookies.

    Third party cookies are required, and the user experience that occurs when third party cookies are blocked--as you've discovered--leaves much to be desired. There is no warning or error message presented to the user.

    You could try to catch the error before it happens. It is possible to detect whether or not third party cookies are blocked by trying to set a cookie on a second domain (that you control) and then making a second request to ensure the cookie is set. You'll need a script or something on your server that can set and check for the cookie (it can't be done using only JavaScript because of the browser security model).

提交回复
热议问题