mirror of https://github.com/dirtbags/moth.git
38 lines
1.1 KiB
HTML
38 lines
1.1 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>Scoreboard</title>
|
|
<link rel="stylesheet" href="basic.css">
|
|
<meta name="viewport" content="width=device-width">
|
|
<link rel="icon" href="images/luna-moth.svg" type="image/svg+xml">
|
|
<link rel="icon" href="images/luna-moth.png" type="image/png">
|
|
</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>
|