Hi,
I'm building a page to display a bunch of webcam images and update them periodically so that the page can be used for at-a-glance monitoring. However, I'm having issues getting the periodic reload working. My code looks something like:
<div class='cameras'>
<div class='camera'>
<h4>Desk</h4>
<img height='240' src='http://somehost/cameras/cam0/lastsnap.jpg' width='320'>
</div>
<div class='camera'>
<h4>Main Room</h4>
<img height='240' src='http://somehost/cameras/cam1/lastsnap.jpg' width='320'>
</div>
<div class='camera'>
<h4>Studio</h4>
<img height='240' src='http://somehost/cameras/cam2/lastsnap.jpg' width='320'>
</div>
</div>
Ideally I'd like to get these things reloading every couple of seconds from their specified URLs without having to generate individual JS for each camera. I've got jQuery in use for a few other bits and pieces, so sticking to that would be great - then again, a plain JS solution is fine too.
Any ideas, StackOverflow JS Gods?