-
Notifications
You must be signed in to change notification settings - Fork 0
/
example.html
executable file
·76 lines (58 loc) · 1.55 KB
/
example.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
<!DOCTYPE html>
<html>
<head>
<META HTTP-EQUIV="refresh" CONTENT="3600">
<title>Sign Display</title>
<link rel="stylesheet" href="style.css" type="text/css">
<script type="text/javascript">
function myEndedListener(){
var myVideo = document.getElementsByTagName('video')[0];
myVideo.addEventListener('ended',myNewSrc,false);
}
var position = 0;
var videoList=new Array(
"movie01.theora.ogv",
"movie02.theora.ogv",
"movie03.theora.ogv"
);
function myNewSrc() {
var myVideo = document.getElementsByTagName('video')[0];
if(++position >= videoList.length) {
position = 0;
}
myVideo.src=videoList[position];
myVideo.load();
myVideo.play();
}
document.documentElement.style.overflow = 'hidden';
// left keyboard arrow keys cycle through videos
document.onKeyDown = function(event) {
if (!event)
event = window.event;
var code = event.keyCode;
if (event.charCode && code == 0)
code = event.charCode;
switch(code) {
case 39:
// Key right.
myNewSrc();
break;
}
event.preventDefault();
};
</script>
</head>
<body class="home" onload="myEndedListener()">
<video src="movie01.theora.ogv" autoplay width="1300" height="900" id="video"></video>
<aside>
<!--Begin-->
<!--End-->
<img src="status.jpg" id="status">
</aside>
<footer>
<img src="logo.jpg" height="100" id="logo">
<h4>Institute for Awesomeness</h4>
<h5>at Super Cool Place</h5>
</footer>
</body>
</html>