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
|
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<head>
<title>Javascript Webcam for Internet Explorer</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script LANGUAGE="JavaScript">
<!-- hide
// "var speed" is the refresh rate adjustment in seconds.
var speed = 1;
var y = 1;
var x = speed + y;
var time = x - y;
var now;
campicture = new Image();
function stopClock() {
x = "off";
document.form0.clock.value = x;
}
function startClock() {
if (x != "off") {
x = x - y;
document.form0.clock.value = x;
if (x <= 1)
{
reload()
}
timerID = setTimeout("startClock()", 1000);
}
}
function reload() {
now = new Date();
var camImg = "http://my.server.com:9999/singleframe/" + "?" + now.getTime();
document.campicture.src = camImg;
x = speed;
document.form0.clock.value = x;
}
//end hide -->
</script>
</head>
<body text="#000066" bgcolor="#FFFFFF" link="#0066FF" vlink="#00AAFF" alink="#FF0000" onload="startClock()">
<FORM action="JScam.html" name="form0">
<CENTER>
<IMG src="webcamstream.jpg" name="campicture" alt="Picture" border=0 reload="60" height=240 width=320>
</CENTER>
<CENTER>
<INPUT type="hidden" name="clock" size="3" value="">
</CENTER>
</FORM>
</body>
</html>
|