/*---------------------------------------------------- ||Banner Ad Rotater v1.01 || || || ||Script by: || ||Anarchos || ||URL: http://www.xs.mw/anarchos || ||E-mail: anarchos3@hotmail.com || ||ICQ: 12007422 || || || ||E-mail or ICQ me if you have any questions or need || ||help setting up your banner ad rotator. Check out || ||my webpage every once in a while for updates to || ||this script. || -----------------------------------------------------*/ //Setup Instructions: //-0) Modify this file then copy and paste it into the
of the webpage to use the banner ad script /*--------------------------- 1) add into your : -----------------------------*/ /*---------------------------- 2) add this code into your webpage where you want the banner ad to be displayed: -----------------------------*/ //-3) time between switching the ad, in milliseconds -\\ var refreshTime = 5000; //- 5000 ms = 5 seconds -\\ //-4) number of ads to rotate -\\ var numAds = 3; function makeAd() { this.width = '' this.height = '' this.src = '' this.href = '' this.mouseover = '' this.sponsor = '' } var ads = new Array() for(var i = 1; i <= numAds; i++) { ads[i] = new makeAd() } //- 5) Copy and paste the lines between the banner definition for //each banner you want to rotate and be sure to change numAds to //the number of banners (look about 15 lines up for numAds) i = 1; /*------------begin banner definition----------*/ ads[i].width = "205" //width of image ads[i].height = "60" //height of image ads[i].src = "../gfx/ads/destinationmanagement.jpg" ads[i].href = "http://www.tropicaltours-ja.com/" //link url ads[i].mouseover = "Destination Management" //text to display when mouse moves over banner ads[i].sponsor = "Destination Management" //text to display for text link under banner i++ /*-------------end banner definition-----------*/ ads[i].width = "205" ads[i].height = "60" ads[i].src = "../gfx/ads/tropicaltours.jpg" ads[i].href = "http://www.tropicaltours-ja.com/" ads[i].mouseover = "Destination Management" ads[i].sponsor = "Tropical Tours" i++ ads[i].width = "205" ads[i].height = "60" ads[i].src = "../gfx/ads/caribbeanworld.jpg" ads[i].href = "http://www.tropicaltours-ja.com/" ads[i].mouseover = "Destination Management" ads[i].sponsor = "Caribbean World" i++ var myCode = ''; do { var n= Math.floor(Math.random() * (numAds + 1) + 1); } while(n > numAds); var current_ad = n; myCode = getCode(n); function getCode(adNumber){ var tempCode = "" tempCode += (' \n') tempCode += ('