I currently have this script to change the image every time the page is reloaded:
<script type="text/javascript"><!--
var img = new Array();
// Add links to the pictures here, duplicate a line and add between the double-quotes
img.push("ad/ad1.png");
img.push("ad/ad2.png");
// How many random pictures you want to display
var num = 1;
// The part where the images are randomed and printed to screen
for(i=0;i<num;i++) {
rand = Math.floor(Math.random()*img.length);
document.write("<img src=\"" + img[rand] + "\" />");
}
//--></script>
Problem:
These are ad images and I'm not very savvy with javascript - how do I get a URL assigned to each individual image in regards to whichever one is loaded at the time? Thanks for your assistance!
Bookmarks