<html>
<body>
<h2>The Navigator Object</h2>
<p>The onLine property returns true if the browser is online:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML =
"navigator.onLine is " + navigator.onLine;
</script>
</body>
</html>