Here is the javascript below which is very easy to use:-
Demo Here
Just copy the codes from below and paste to your
LAYOUT > ADD PAGE ELEMENT > HTML/JAVASCRIPT
<script type="text/javascript">
var imgs1 = new Array("http://anshuldudeja55.googlepages.com/banner-linkworth2.gif","https://www.sfimg.com/Images/Banners/banner164.gif","https://www.sfimg.com/Images/Banners/Banner12.gif","https://www.sfimg.com/Images/Banners/Banner13.gif","http://anshuldudeja55.googlepages.com/anshuldudeja.jpg");
var lnks1 = new Array("http://www.linkworth.com/?a=15034","http://www.ezinfocenter.com/10142921/CB","http://www.ezinfocenter.com/10142921/CB","http://www.ezinfocenter.com/10142921/CB","http://anshuldudeja.blogspot.com");
var alt1 = new Array();
var currentAd1 = 0;
var imgCt1 = 5;
function cycle1() {
if (currentAd1 == imgCt1) {
currentAd1 = 0;
}
var banner1 = document.getElementById('adBanner1');
var link1 = document.getElementById('adLink1');
banner1.src=imgs1[currentAd1]
banner1.alt=alt1[currentAd1]
document.getElementById('adLink1').href=lnks1[currentAd1]
currentAd1++;
}
window.setInterval("cycle1()",9000);
</script>
<a id="adLink1" href="http://anshuldudeja.blogspot.com" target="_blank">
<img id="adBanner1" border="0" width="125" src="http://anshuldudeja55.googlepages.com/anshuldudeja.com.png" height="125"/></a>
INSTALLATION
1) Links in red are url to the images you using in Banner So change them acc to your images.
2) Links in green are the web address to images so modify them.
3) var imgCt1 = 5; in brown is 5 i.e total no of images you using so change it to how many images you are using.
4) window.setInterval("cycle1()",9000); in orange is 9000 is the ime interval at which time the banner changes to adjust it according to your needs.
5) Height and width are 125 the size of default add you are using to start load.
I hope you will enjoy using this and show off your all sponsors now.
No comments:
Post a Comment