Why does this internet check not work on the WebGL Platform

This my code for checking for an internet connection on startup. It works on iOS, Android, Mac and Windows, but fails on WebGL. Ignoring the wierdness of checking for an internet connection in a WebGL build, I’m just curious why it fails ? It basically just checks that it can access google.com

            UnityWebRequest www = new UnityWebRequest(internetCheckURL);
            www.SendWebRequest();
            float elapsedSecond = 0f;

            while (!www.isDone)
            {
                elapsedSecond += internetCheckRate;
                if (elapsedSecond >= 12.0f && www.downloadProgress <= 0.5)
                {
                    break;
                }
                else
                {
                    checkInternetMessage.text += ".";
                    yield return new WaitForSecondsRealtime(internetCheckRate);
                }
            }

            if (!www.isDone || !string.IsNullOrEmpty(www.error))
            {
                Debug.LogError("No internet connection, retrying...");
                StartCoroutine("CheckConnection");
                yield break;
            }
            else if (www.isDone && string.IsNullOrEmpty(www.error))
            {
                Debug.Log("Internet Connection Detected");
                checkInternetMessage.text = "Internet Connection Dectected.";
                this.gameObject.SetActive(false);
            }
        }

There are some restrictions on WebGL - specifically accessing web resources that aren’t on the same server as the WebGL project.

From the docs:

“Basically any WWW request to a server which is different from the server hosting the WebGL content needs to be authorized by the server you are trying to access. To access cross-domain WWW resources in WebGL, the server you are trying to access needs to authorize this using CORS.”

Thats probably the reason. I guess i’ll just check my own server for the connection instead. Thank you very much!