how to judge client's network off-line or online use JavaScript? -


this question has answer here:

if(window.navigator.online==true){      alert("connect success")   }else{      alert("fail")  }

window.navigator.online return true whatever in off-line or online.any other methods solve problem? thanks.

if understood issue correctly, answered here : detect internet connection offline?

we can mark duplicate same question.


Comments

Popular posts from this blog

python - Operations inside variables -

Generic Map Parameter java -

arrays - What causes a java.lang.ArrayIndexOutOfBoundsException and how do I prevent it? -