foxytease07 0 Newbie Poster

I have been trying to work on this for awhile now and this is the last part of 9 that I have to do for my project and I have come close but I just can’t figure it out.

What I have to do:
There is a banner ad at the top of the index page called banner1.jpg. Create a cycling banner ad using the 3 banner ad images supplied on the disk (bannerad1.jpg, bannerad2.jpg and bannerad3.jpg). Add a link to bannerad2 that will take the user to www.bigmtn.com and add a link to bannerad3 that will take the user to www.bridgerbowl.com

All I need help with is the bolded part which is the links. I have the cycling banner working. There are three ads and they as asking for links on the 2nd and third link. If someone could please point me in the right direction of the codes for this it would be appreciated. I am asking for some guidance.

This is what I have that the links do not work:

<SCRIPT LANGUAGE="JAVASCRIPT">
<!-- Hide from old browers

window.onload = initBannerLink;

var thisAd= 0;

function initBannerLink() {
if (document.getElementById("adBanner").parentNode.tagName == "A") {
document.getElementById("adBanner").parentNode.onclick = newLocation;
}
rotate();
}

function newLocation() {
document.location.href = "http://www." + adURL[thisAd];
return false;
}

var banners = new Array("bannerad1.jpg","bannerad2.jpg","bannerad3.jpg")
var adURL = new Array("","bigmtn.com","bridgerbowl.com")
var bnrCntr = 0
function bancycle() {
bnrCntr = bnrCntr + 1
if (bnrCntr == 3) {
bnrCntr = 0
}
document.Bannerad.src = banners[bnrCntr]
setTimeout("bancycle()",3000)
}


//-->
</SCRIPT>