2016-09-06 10:14:54 +02:00
|
|
|
<div id="wrapper">
|
2016-09-18 21:51:19 +02:00
|
|
|
<div class="container" style="margin:20px auto;max-width:600px;">
|
2016-09-17 23:37:44 +02:00
|
|
|
<center>
|
2016-09-18 21:51:19 +02:00
|
|
|
<img src="img/hyperion/hyperionlostconnection.png" alt="Redefine ambient light!">
|
2016-09-17 23:37:44 +02:00
|
|
|
<div>
|
|
|
|
<h2>Lost connection to Hyperion service!<h1>
|
|
|
|
<hr>
|
|
|
|
<h4>Possible reasons:</h4>
|
|
|
|
<p>1. Hyperion restarts</p>
|
|
|
|
<p>2. You perform an update</p>
|
|
|
|
<p>3. An older browser session</p>
|
|
|
|
<p>3. Hyperion isn't running</p>
|
|
|
|
<hr>
|
|
|
|
<i class="fa fa-refresh fa-spin" style="font-size:50px"></i>
|
|
|
|
<h4>This page will be automatically refreshed.</h4>
|
|
|
|
<h4>We reconnect again after Hyperion is available.</h4>
|
|
|
|
<a href="/">If not, click me</a>
|
|
|
|
</div>
|
|
|
|
</center>
|
2016-09-06 10:14:54 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2016-09-07 20:10:37 +02:00
|
|
|
|
|
|
|
<!-- ************************************ -->
|
|
|
|
|
2016-09-06 10:14:54 +02:00
|
|
|
<script>
|
2016-09-07 20:10:37 +02:00
|
|
|
var connectionLost = false;
|
|
|
|
var connectionTimer;
|
|
|
|
|
|
|
|
function tryReconnect()
|
|
|
|
{
|
|
|
|
$.ajax({ url: "/" }).done(function(data) {
|
|
|
|
window.clearInterval(connectionTimer);
|
|
|
|
window.location.href ="/";
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
2016-09-06 10:14:54 +02:00
|
|
|
function connectionLostAction()
|
|
|
|
{
|
2016-09-07 20:10:37 +02:00
|
|
|
connectionLost = true;
|
|
|
|
connectionTimer = window.setInterval(tryReconnect, 5000);
|
2016-09-06 10:14:54 +02:00
|
|
|
}
|
2016-09-07 20:10:37 +02:00
|
|
|
|
2016-09-06 10:14:54 +02:00
|
|
|
</script>
|
|
|
|
|
|
|
|
|