adImages = new Array(
	"placeholders/p1.gif",
	"banners/bricabrackorner.jpg",
	"banners/castilecreekkennels.gif",
	"placeholders/p19.gif",
	"placeholders/p18.gif",
	"banners/acer.jpg",
	"banners/leggspeafowl.gif",
	"placeholders/p3.gif",
	"banners/plattsburgclinicpharmacy.gif",
	"placeholders/p8.gif",
	"banners/sherwoodfamilyfarms.gif",
	"banners/dayspring.jpg",
	"banners/kccoyote.jpg",
	"banners/acer.jpg",
	"placeholders/p7.gif",
	"banners/crenshaw.jpg",
	"banners/crenshaw2.jpg",
	"placeholders/p11.gif",
	"placeholders/p12.gif",
	"placeholders/p13.gif",
	"placeholders/p14.gif",
	"placeholders/p15.gif",
	"placeholders/p16.gif");
adURL = new Array(
	"mailto: support@isotech-inc.com",
	"http://www.bricabrackorner.com",
	"http://www.castilecreekkennels.com",
	"mailto: support@isotech-inc.com",
	"mailto: support@isotech-inc.com",
	"mailto: JLSaunders@realtor.com",
	"http://www.leggspeafowl.com",
	"mailto: support@isotech-inc.com",
	"http://www.plattsburgclinicpharmacy.com",
	"mailto: support@isotechnetworks.net",
	"http://www.sherwoodfamilyfarms.com/",
	"mailto: sales@isotech-inc.com",
	"http://www.kccoyote.com/",
	"mailto: sales@isotech-inc.com",
	"mailto: support@isotech-inc.com",
	"mailto: docc@grm.net",
	"mailto: docc@grm.net",
	"mailto: support@isotech-inc.com",
	"mailto: support@isotech-inc.com",
	"mailto: support@isotech-inc.com",
	"mailto: support@isotech-inc.com",
	"mailto: support@isotech-inc.com",
	"mailto: support@isotech-inc.com");
imgCount = adImages.length;
firstTime = true;


//while loops used to make sure 2 of the the same ad is not displayed at the same time
function rotate(){
	if (document.images) {
		thisAd1 = Math.floor(Math.random()*imgCount);
		
		thisAd2 = Math.floor(Math.random()*imgCount);
		while (thisAd2 == thisAd1){thisAd2 = Math.floor(Math.random()*imgCount);}
		
		thisAd3 = Math.floor(Math.random()*imgCount);
		while (thisAd3 == thisAd1 || thisAd3 == thisAd2){thisAd3 = Math.floor(Math.random()*imgCount);}
		
		thisAd4 = Math.floor(Math.random()*imgCount);
		while (thisAd4 == thisAd3 || thisAd4 == thisAd2 || thisAd4 == thisAd1){thisAd4 = Math.floor(Math.random()*imgCount);}
		
		thisAd5 = Math.floor(Math.random()*imgCount);
		while (thisAd5 == thisAd4 || thisAd5 == thisAd3 || thisAd5 == thisAd2 || thisAd5 == thisAd1){thisAd5 = Math.floor(Math.random()*imgCount);}
		
		thisAd6 = Math.floor(Math.random()*imgCount);
		while (thisAd6 == thisAd5 || thisAd6 == thisAd4 || thisAd6 == thisAd3 || thisAd6 == thisAd2 || thisAd6 == thisAd1){thisAd6 = Math.floor(Math.random()*imgCount);}
		
		thisAd7 = Math.floor(Math.random()*imgCount);
		while(thisAd7 == thisAd6 || thisAd7 == thisAd5 || thisAd7 == thisAd4 || thisAd7 == thisAd3 || thisAd7 == thisAd2 || thisAd7 == thisAd1){thisAd7 = Math.floor(Math.random()*imgCount);}
		
		thisAd8 = Math.floor(Math.random()*imgCount);
		while(thisAd8 == thisAd7 || thisAd8 == thisAd6 || thisAd8 == thisAd5 || thisAd8 == thisAd4 || thisAd8 == thisAd3 || thisAd8 == thisAd2 || thisAd8 == thisAd1){thisAd8 = Math.floor(Math.random()*imgCount);}
	}
	document.adBanner1.src=adImages[thisAd1];
	document.adBanner2.src=adImages[thisAd2];
	document.adBanner3.src=adImages[thisAd3];
	document.adBanner4.src=adImages[thisAd4];
	document.adBanner5.src=adImages[thisAd5];
	document.adBanner6.src=adImages[thisAd6];
	document.adBanner7.src=adImages[thisAd7];
	document.adBanner8.src=adImages[thisAd8];
	setTimeout("rotate()",15*1000);
}

function newURL1() {document.location.href = adURL[thisAd1];}
function newURL2() {document.location.href = adURL[thisAd2];}
function newURL3() {document.location.href = adURL[thisAd3];}
function newURL4() {document.location.href = adURL[thisAd4];}
function newURL5() {document.location.href = adURL[thisAd5];}
function newURL6() {document.location.href = adURL[thisAd6];}
function newURL7() {document.location.href = adURL[thisAd7];}
function newURL8() {document.location.href = adURL[thisAd8];}
