Simple enough in JavaSCRIPT, don't know about Java.
Basically, as long as every element in the web document has a unique ID, you can manipulate or read just about anything for that element, including the source. And JavaScript has a "setTimeout" function that can do the "every 10 seconds" part.
So, let's use the following arbitrary code as an example:
HTML Code:
<img id="img1" src="/images/image1.gif" />
Inside the HEAD tags at the top, you can do something like:
Code:
function swapImage() {
var thisImg = document.getElementById('img1');
thisImg.src = "/images/image2.png";
setTimeout("swapImage()",10000);
}
window.onload = swapImage;
Now.. this will only change the source to image2.png, and will reset to image2.png every ten seconds. But you can create an array of image names and use those referencing the array index and setting a variable to increment by one with each iteration; stipulate that once the variable gets to the max length of the array, reset to zero.
Bookmarks