// Set display and fade times
var commentsDisplayTime = 5.0;
var commentsFadeTime = 1.5;

// Retrieve list of images (defined on page)
var commentsImageList = SetCommentsImages();
var commentsCurrentImage = 0;

// Pre-load images
var i;
var commentsImages = new Array();
for (i = 0; i < commentsImageList.length; i++)
{
	commentsImages[i] = new Image();
	commentsImages[i].src = commentsImageList[i];
}

// Run slide show
function RunCommentsSlideShow()
{
	if (document.all)
	{
		//document.images.SlideShow.style.filter="blendTrans(duration=3)"
		document.images.CommentsSlideShow.style.filter="blendTrans(duration=" + commentsFadeTime + ")";
		document.images.CommentsSlideShow.filters.blendTrans.Apply();
	}

	document.images.CommentsSlideShow.src = commentsImages[commentsCurrentImage].src;

	if (document.all)
	{
		document.images.CommentsSlideShow.filters.blendTrans.Play();
	}

	//	Set next image to display (reset if image number exceeds number of images)
	commentsCurrentImage = commentsCurrentImage + 1;
	if (commentsCurrentImage >= commentsImageList.length)
		commentsCurrentImage = 0;

	// Set time before next image is displayed
	setTimeout('RunCommentsSlideShow()', (commentsFadeTime + commentsDisplayTime) * 1000);
}


