Hi,
I want to store the data which is coming from backend by using local Storage when it is in online mode and get the data from local storage when it is in offline mode.
For that first I need to check that the Network is in online or offline Mode.
I am doing desktop application.In that I am using
if(navigator.onLine == true){
alert("online");
}else{
alert("offline");
}
But when I disable the Network I am getting the alert like online.
How to find that the application is in Online mode or offline mode?
How to get the Offline alert when there is no network available?
Please Help me.
Thanks&Regards
Sridevi