var wichimage=1
var linkAddress
var slideSpeed = 4500
var crossFadeDuration = 2
var Pic = new Array(
			new Array("/p_cards/ad_1_small.jpg", "210", "138"),
			new Array("/p_cards/ad_2_small.jpg", "210", "140"),
			new Array("/p_cards/ad_3_small.jpg", "210", "147"),
			new Array("/p_cards/ad_4_small.jpg", "145", "210"),
			new Array("/p_cards/ad_5_small.jpg", "145", "210")
		);

var t
var j = 0
var p = Pic.length
var preLoad = new Array()
for (i = 0; i < p; i++){
	 preLoad[i] = new Image()
	 preLoad[i].src = Pic[i][0]
	 preLoad[i].width = Pic[i][1]
	 preLoad[i].height = Pic[i][2]
}

function runSlideShow(){
	 if (document.all){
		document.images.SlideShow.style.filter="blendTrans(duration=10)"
		document.images.SlideShow.style.filter="blendTrans(duration=crossFadeDuration)"
		document.images.SlideShow.filters.blendTrans.Apply()		
	 }
	 document.images.SlideShow.src = preLoad[j].src
	 document.images.SlideShow.width = preLoad[j].width
	 document.images.SlideShow.height = preLoad[j].height
	 if (document.all){
		document.images.SlideShow.filters.blendTrans.Play()
	 }
	 wichimage = j
	 j = j + 1
	 if (j > (p-1)) j=0
	 t = setTimeout('runSlideShow()', slideSpeed)
}

function slidelink(){
	if (wichimage==0)
		window.open("/pictures.asp?picture=ad1")
	else if (wichimage==1)
		window.open("/pictures.asp?picture=ad2")
	else if (wichimage==2)
		window.open("/pictures.asp?picture=ad3")
	else if (wichimage==3)
		window.open("/pictures.asp?picture=ad4")
	else if (wichimage==4)
		window.open("/pictures.asp?picture=ad5")
}
function MM_preloadImages() { //v3.0
	var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
	var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
	if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}