S
src_mag
Hello,
I'd like to write JavaScript code that refreshes a frame once a second
loading a different image each time. Basically, here's what the script
would do:
0 sec load img0.gif
1 sec load img1.gif
2 sec load img2.gif
3 sec load img0.gif (back to the first image)
4 sec load img1.gif
....etc...
I do have some code that reloads the frame every second, but it always
loads the same image:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<title>My Frame</title>
<style type="text/css" id="mtmsheet"></style>
</head>
<body bgcolor = "#cedfea">
<h4 align="center">CAMERA #1</h4>
<img src="img0.jpg" name="image0" align=right></img>
<script language="javascript">setTimeout("window.location.reload(true)",1000);</script>
</body>
</html>
Any idea on how I could modify this script to load a different image
at each refresh? Any feedback is greatly appreciated.
Thanks.
SRC
I'd like to write JavaScript code that refreshes a frame once a second
loading a different image each time. Basically, here's what the script
would do:
0 sec load img0.gif
1 sec load img1.gif
2 sec load img2.gif
3 sec load img0.gif (back to the first image)
4 sec load img1.gif
....etc...
I do have some code that reloads the frame every second, but it always
loads the same image:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<title>My Frame</title>
<style type="text/css" id="mtmsheet"></style>
</head>
<body bgcolor = "#cedfea">
<h4 align="center">CAMERA #1</h4>
<img src="img0.jpg" name="image0" align=right></img>
<script language="javascript">setTimeout("window.location.reload(true)",1000);</script>
</body>
</html>
Any idea on how I could modify this script to load a different image
at each refresh? Any feedback is greatly appreciated.
Thanks.
SRC