so I have my own affiliate banner system going on my site. I have a javascript code for running my banners which are supposed to be clickable links. But when the system is running none of the ads are clickable. Any ideas?
Here is the stripped down code, the only thing missing is the affiliate links.
<script language="JavaScript"> <!-- Begin hiding script from older browsers // Replace the images inside the double-quotes to your own images // You may have any number of images adImages = new Array("image1","image2","image3") // Replace the quotes to inside the double-quotes to your own quotes // You may have any number of quotes but they must equal the number of images that rotate quote = new Array("This is Image 1","This is Image 2","This is Image 3") // Replace the quotes to inside the double-quotes to your links adURL = new Array ("url1","url2","url2") thisAd = 0 imgCt = adImages.length quoteCt = quote.length function rotate() { if (document.images) { if (document.cycle.complete) { thisAd++ if (thisAd == imgCt && thisAd == quoteCt) { thisAd = 0 } document.cycle.src = adImages[thisAd]; window.defaultStatus = quote[thisAd]; } // This sets the interval to which the images and quotes are rotated. 1000 equals 1 second setTimeout("rotate()", 3500) } } function rotateLink() { window.parent.location.href = "http://" + adURL[thisAd] } // End hiding script from older browsers --> </script> <body onLoad="rotate()"> <!-- Add an anchor tag to the image to call the rotateLink function of the script for links --> <p align="center"><img src="image1" width="300" height="150" border="0" name="cycle"></p>
i won't use google adsense because, honestly, I don't trust it.
Edited by Dragon, 20 May 2006 - 11:36 AM.