
<!--
fadeStep=5; // Size of the fade "step". Must be a multiple of 100.

fadeInterval=10; // Amount of time in-between the increments of fading

readingTime=300; // Amount of time the user has to see the image (seconds)


//Change Pictures here/
images=new Array
("images/registration.jpg : page.php?ID=264&MID=359",
"images/feature_summerclub2010.jpg : page.php?ID=199&MID=174",
"images/feature_greentours.jpg : page.php?ID=124",
"images/feature_wiibowl.jpg : page.php?ID=97&MID=358",
"images/feature_ancestry-class.jpg : page.php?ID=317&MID=358",
"images/feature_story2010.jpg : page.php?ID=215&MID=346");

/* Do not edit the following variables */
var currTransp=100;
var currDir=0;
var currNum=0;
var calculatedSurplus=(100/fadeStep)*fadeInterval;

function nextSlide()
{
currNum++;
if(currNum == images.length)
{
currNum=0;
}
document.getElementById("disp-slide").src=images[currNum].split(" : ")[0];
document.getElementById("disp-link").href=images[currNum].split(" : ")[1];
}

function prevSlide()
{
currNum--;
if(currNum == -1)
{
currNum=images.length-1;
}
document.getElementById("disp-slide").src=images[currNum].split(" : ")[0];
document.getElementById("disp-link").href=images[currNum].split(" : ")[1];
}

function fadeSlide()
{

john=window.setTimeout("fadeSlide()", fadeInterval);

if(currTransp == 100 - fadeStep && currDir == 1)
{
window.clearTimeout(john);
}

if(currTransp < 0)
{
currTransp=0;
}

if(currTransp > 100)
{
currTransp=100;
}

if(currDir==0 && currTransp > 0)
{
currTransp=currTransp-fadeStep;

if(navigator.appName=="Netscape")
{
document.getElementById("disp-slide").style.MozOpacity=currTransp/100;
}

if(navigator.appName=="Microsoft Internet Explorer")
{
document.getElementById("disp-slide").style.filter="alpha(opacity="+currTransp+")";
}

}


else if(currDir==1 && currTransp < 100)
{
currTransp=currTransp+fadeStep;

if(navigator.appName=="Netscape")
{
document.getElementById("disp-slide").style.MozOpacity=currTransp/100;
}

if(navigator.appName=="Microsoft Internet Explorer")
{
document.getElementById("disp-slide").style.filter="alpha(opacity="+currTransp+")";
}

}

else if(currDir==0 && currTransp == 0)
{
currDir=1;
nextSlide();
}

}

function commenceFade()
{
currDir=0;
fadeSlide();
}

window.setInterval("commenceFade()", 10000 );

//-->
