function slideShow(imgArray,imgDiv)
{
	var curImgIdx = Math.floor(Math.random()*imgArray.length);
	this.init = function()
	{
		for(var i=0 ; i < imgArray.length ; i++)
		{
			var tmpImgEl = document.createElement("img");
			tmpImgEl.setAttribute("src",(imgArray[i][0].replace('&amp;','&')));
			tmpImgEl.setAttribute("id",imgArray[i][1]);
			tmpImgEl.setAttribute("alt","");
			tmpImgEl.style.opacity = 0;
			tmpImgEl.style.filter = "alpha(opacity=0)";
			document.getElementById(imgDiv).appendChild(tmpImgEl);

		}
		if(document.getElementById('slideShowInit')==null) { fadein(imgArray[curImgIdx][1],0.1); }
		// document.getElementById(imgArray[curImgIdx][1]).style.zIndex = 1000;
		// fadein(imgArray[curImgIdx][1],0.1);
	}
	
	this.causeRotate = function()
	{
		var newList = new Array();
		for(var j=0 ; j<imgArray.length ; j++) { newList[j] = j; }
		newList.splice(curImgIdx,1);
		var nextImgIdx = newList[Math.floor(Math.random() * newList.length)];
		
		document.getElementById(imgArray[nextImgIdx][1]).style.zIndex = 1000;
		document.getElementById(imgArray[curImgIdx][1]).style.zIndex = 500;
		
		window.setTimeout("fadein('"+imgArray[nextImgIdx][1]+"',0.1);",50);
		window.setTimeout("fadeout('"+imgArray[curImgIdx][1]+"',1);",2050);
		curImgIdx = nextImgIdx;
	}
}