Back to index

Cycling Banner Ad 001

 

 

 

Script instructions for <HEAD></HEAD> tags

<SCRIPT LANGUAGE="JAVASCRIPT" TYPE="TEXT/JAVASCRIPT">
adImages = new Array("images/wickedbanner.gif","images/freejavabanner.gif")
adURL = new Array("wickedniftystuff.com","freejavascriptscd.com")
thisAd = 0
imgCt = adImages.length
function rotate() {
if(document.images) {
if(document.adBanner.complete){
thisAd++
if(thisAd == imgCt) {
thisAd = 0
}
document.adBanner.src=adImages[thisAd]
}
setTimeout("rotate()",3*1000)
}
}
function newLocation() {
document.location.href="http://www."+adURL[thisAd]
}

</SCRIPT>
 

Script goes in the <BODY> tag of the HTML Document

onLoad="rotate()"

Paste script where needed in the HTML Document

<p align="center">
<A href="javascript:newLocation()"><img border="2" src="images/wickedbanner.gif" width="468" height="60" name="adBanner"></A></p>
 

Paste script between the <HEAD></HEAD> tags.


Paste script where needed in the body of the HTML Document.

 


Copyright 2003 Ultimatephp.com