mirror of https://github.com/dirtbags/moth.git
34 lines
855 B
HTML
34 lines
855 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>Scoreboard</title>
|
|
</head>
|
|
<body style="margin: 0; padding: 0; height: 100%; overflow: hidden;">
|
|
<div style="position:absolute; left: 0; right: 0; bottom: 0; top: 0px;">
|
|
<iframe id="content" src="scoreboard.html" style="border:none;" height="100%" width="100%"></iframe>
|
|
</div>
|
|
</body>
|
|
<script>
|
|
var cycle = ["scoreboard.html", "scoreboard-all.html", "scoreboard-timeline.html"];
|
|
var current = 0;
|
|
var timeout = 25000;
|
|
var curTimeout;
|
|
curTimeout = setInterval(update, timeout);
|
|
function update()
|
|
{
|
|
if(curTimeout)
|
|
{
|
|
clearInterval(curTimeout);
|
|
}
|
|
current++;
|
|
if(current >= cycle.length)
|
|
{
|
|
current = 0;
|
|
}
|
|
//console.log(cycle[current]);
|
|
document.getElementById("content").src = cycle[current];
|
|
curTimeout = setInterval(update, timeout);
|
|
}
|
|
</script>
|
|
</html>
|