navigator.onLine always reporting true
-
I am needing to see if the use is online before running an function.
I intended to use navigator.onLine but it is always reporting true, even if no network is connected. just to ensure this, i put airplane mode ON (Android OS) so no connection is there, and it is still reporting navigator.onLine = true. Confusing part, this WAS working a few days ago, but now, no joy… Any help is appreciated…
-
@dustintinsley You can try:
document.addEventListener("online", yourCallbackFunction, false);
OR
https://stackoverflow.com/questions/14283124/navigator-online-not-always-working
-
Dumb mistake on my end. I removed Network Information plugin from my project. Adding it back, everything once gain works…