/// Main page slideshow2010 BETA
var initloop = true;
var eltSlideShow;
var eltCaptions;
var eltAds0;
var eltContent;

var ffTest;

var eltFilmStrip1;
var eltFilmStrip2;
var eltFilmStrip3;
var eltFilmStrip4;

//var eltTest99;
var maxdivs = 7;
var is = new Is();

var intLeftAlley = 248+ 'px;'
var imgHeight = 200
var adImageWidth= 260+'px;'
var adImageHeight= 100+'px;'
var slideShowTop = '265px;'
var captionTopLine = imgHeight+265 + 'px;'
var adToggle=0;

//User defined variables - change these variables to alter the behaviour of the script
var ImageFolder = "/Images/Ads/"; //Folder name containing the images
var ImageFileNames = new Array('Capstone1L.jpg', 'SportsSpectrumL.jpg'); //List of images to use
var ImageURLs = new Array('http://www.amazon.com/exec/obidos/redirect?tag=brettbcom&path=subst/home/home.html', 'http://www.iplus.zetnet.co.uk/', 'http://www.amazon.com/exec/obidos/redirect?tag=brettbcom&path=subst/home/home.html', 'http://www.iplus.zetnet.co.uk/'); //List of hyperlinks associated with the list of images
var DefaultURL = 'http://www.hspn.net/default.asp'; //Default hyperlink for the Banner Ad
// -----------------------
var DisplayInterval = 4; //Number of seconds to wait before the next image is displayed
// -----------------------
var TargetFrame = ""; //Name of the frame to open the hyperlink into
//Internal variables (do not change these unless you know what you are doing)

// Defaults: --------
var ctrlMainLooping = 1;
var offsetMainSlideShow = 0;
var MainSlideshowImageNum = 0
var startMainSlideshowImageNum = 0;
var selectedCaptionNum = 0;
var refreshMainSlideShowImage = true;
// ------------------

var IsValidBrowser = false;
var BannerAdCode = 0;
var ciInitIndex = 0;
var Adcounter = 0;
/// -------------------------------
var maxAds = 6;
/// -------------------------------
var maxMainSlideshowImageNum = 23;
/// -------------------------------
var startAd = 0;

var oLayer = eval('eltAds0');
var oSlideShow = eval('eltSlideShow');
var oCaptions = eval('eltCaptions');

DisplayInterval = DisplayInterval * 1000;
//var NumberOfImages = ImageFileNames.length;
var NumberOfImagesa = 39;
var CountofDivs = 27;

var gBrowserType = navigator.appName;
//Add a trailing forward slash to the ImageFolder variable if it does not already have one
if (ImageFolder.substr(ImageFolder.length - 1, ImageFolder.length) != "/" && ImageFolder != "") { ImageFolder += "/";}
if (TargetFrame == '')
{
	var FramesObject = null;
}	
else
{
	var FramesObject = eval('parent.' + TargetFrame);
}


function Is ()
{   // convert all characters to lowercase to simplify testing
    var agt=navigator.userAgent.toLowerCase()


	ffTest = agt.indexOf('firefox');

    // --- BROWSER VERSION ---
    this.major = parseInt(navigator.appVersion)
    this.minor = parseFloat(navigator.appVersion)

    this.nav  = ((agt.indexOf('mozilla')!=-1) && ((agt.indexOf('spoofer')==-1)
                && (agt.indexOf('compatible') == -1)))
    this.nav2 = (this.nav && (this.major == 2))
    this.nav3 = (this.nav && (this.major == 3))
    this.nav4 = (this.nav && (this.major >= 4))
		
    this.ie   = (agt.indexOf("msie") != -1)
    this.ie3  = (this.ie && (this.major == 2))
    this.ie4  = (this.ie && (this.major == 4))

    this.opera = (agt.indexOf("opera") != -1)
     
    this.nav4up = this.nav && (this.major >= 4)
    this.nav5up = this.nav4up && (navigator.userAgent.indexOf("Firefox")!=-1)

    this.ie4up  = this.ie  && (this.major >= 4)
}
function init_vars()
	{
		eltSlideShow = getElt("Slideshow");
		eltAds0 = getElt("HomePageBannerAd");
		eltCaptions = getElt("MainCaptions");
		eltContent = getElt("Content");
		eltFilmStrip1 = getElt("filmstrip1");
		eltFilmStrip2 = getElt("filmstrip2");
		eltFilmStrip3 = getElt("filmstrip3");
		eltFilmStrip4 = getElt("filmstrip4");
		
		//eltWaitBox = getElt("WaitBox");
		//showContent();
	}

function getElt () 
{
 if (is.nav5up) {
    var currentLayer = document.getElementById([getElt.arguments[0]]);
    return currentLayer;
  } 
  else if (is.ie4up ) {
    var elt = eval('document.all.' + getElt.arguments[getElt.arguments.length-1]);
    return(elt);
  }
  else if (is.nav4up) {
	//showit(document.layers[0]);
    var currentLayer = document.layers[getElt.arguments[0]];

    for (var i=1; i<getElt.arguments.length && currentLayer; i++)
    {   currentLayer = currentLayer.document.layers[getElt.arguments[i]];
    }
    return currentLayer;
    }
}

function clearWait() {
	document.all.WaitBox.style.display = 'none';
  document.all.Content.style.visibility = 'visible';
}
function showContent()  {
	var oLayer = eval('eltContent');

	if (is.nav5up)
		{
		oLayer.style.visibility = "visible";
		}
	else if (is.nav4up)
		{
		oLayer.visibility = "visible";
		document.layers[0].visibility = "hidden";
		}
	else
		{
		oLayer.style.visibility = "visible";
		}
}
function showMe(d) {
	var oLayer = eval('eltAds' + d);
	if (is.nav4up)
		{
		oLayer.visibility = "visible";
		}
	else
		{
		oLayer.style.visibility = "visible";
		}
}
var adsF = new Array;
adsF[0] = '<a href="http://www.hspn.net/showcase/?showcase=3" target=_new><img alt="" title="" src="http://www.hspn.net/images/theshowcase/lindenfogproductions/here4youbanner2.jpg" width="' + adImageWidth + '" height="' + adImageHeight + '" align=top border=0><br><b>Here For You Funding</b></a>';
adsF[1] = '<a href="http://www.oblockbooks.com"><img alt="" title="" src="http://www.hspn.net/images/sponsors/OblockBookbannerAd.jpg" width="' + adImageWidth + '" height="' + adImageHeight + '" align=top border=0><br><b>O\'Block Books</b></a>';
adsF[2] = '<a href="http://www.hspn.net/showcase/?showcase=3" target=_new><img alt="" title="" src="http://www.hspn.net/images/theshowcase/lindenfogproductions/here4youbanner2.jpg" width="' + adImageWidth + '" height="' + adImageHeight + '" align=top border=0><br><b>Here For You Funding</b></a>';
adsF[3] = '<a href="http://www.hspn.net/showcase/?showcase=0" target=_new><img alt="" title="" src="http://www.hspn.net/Images/theShowCase/LindenfogProductions/ChristianFreedomInternationalNepal.jpg" width="' + adImageWidth + '" height="' + adImageHeight + '" align=top border=0><br><b>Christian Freedom International</b></a>';
adsF[4] = '<a href="http://www.lifeway.com/" target=_new><img alt="LifeWay Christian Stores" title="LifeWay Christian Stores" src="http://www.hspn.net/Images/EastCoast/Sponsors/lifeway.jpg" width="' + adImageWidth + '" height="' + adImageHeight + '" align=top border=0></A>';
adsF[5] = '<a href="http://www.advocare.com/08061077/Store/"><img src="http://www.hspn.net/images/advocare/advocare.jpg" width="' + adImageWidth + '" height="' + adImageHeight + '" align=top border=0><br><center><font face="Arial" size="2" color="black"><br><b>Advocare Products</b></a></center>';
adsF[6] = '<a href="http://www.scoreinternational.org"><img src="http://www.hspn.net/images/eastcoast/sponsors/score logo color.jpg" width="' + adImageWidth + '" height="' + adImageHeight + '" align=top border=0><br><center><font face="Arial" size="2" color="black"><br><b>SCORE INTERNATIONAL</b></a></center>';



// template = '<a href=""><img src="" width="' + adImageWidth + '" height="' + adImageHeight + '" align=left border=0><br><center><font face="Arial" size="2" color="black"><b></b></a></center>';

//adsF[4] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4333" target= "_new" alt="This company helps your team raise money for tournament and travel expenses ..."><img alt="Want to get the funds to get you to the tournament? Check these guys out!" src="http://www.hspn.net/Images/EastCoast/Sponsors/mysportsdream.gif" width="260" height="99" align=left border="0"></a></font>';
//adsF[7] = '<a href="#kickcoach"><img alt="The Kick Coach is the ULTIMATE at home soccer training product!" title="The Kick Coach is the ULTIMATE at home soccer training product!"  src="http://www.hspn.net/Images/EastCoast/Sponsors/kickcoach.jpg" width="220" height="99" align=left border="0">The Kick Coach is the ULTIMATE at-home soccer training product!. Details... </a></font>';
//adsF[12] = '<a href="http://www.championsgt.com.com/" target=_new><img alt="AAU Champions Junior Golf Tour" title="AAU Champions Junior Golf Tour" src="http://www.hspn.net/Images/EastCoast/Sponsors/cjgt_new.gif" width="220" height="99" align=top border=0></A>';
//adsF[13] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4421" target= "_new"><img src="http://www.hspn.net/images/advocare/excelGel.gif" align="left" width="190" height="99"  alt="Electrolyte replacement energy gel" title="Electrolyte replacement energy gel" border="0"></a>';
//adsF[14] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4253" target= _new"><img src="http://www.hspn.net/images/Advertisers/myhomeschoolrewardsAdJuly2008.jpg" width="260" height="99"  align="left" alt="Use giftcards for everyday purchases and get cash back" title="Use giftcards for everyday purchases and get cash back"></a><font face="arial" size="2">'
//adsF[15] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4421" target= "_new"><img src="http://www.hspn.net/images/advocare/SPARK.gif" align="left" height="99" width="260" alt="Vitamin and Amino Acid Energy Supplement" title="Vitamin and Amino Acid Energy Supplement" border="0"></a>';
//adsF[16] = '<img src="http://www.hspn.net/images/clipart/WOG.jpg" width="220" height="99" align="left" alt="Whether therefore ye eat, or drink, or whatsoever ye do, do all to the glory of God (I Cor. 10:31)" title="Whether therefore ye eat, or drink, or whatsoever ye do, do all to the glory of God (I Cor. 10:31)">';
//adsF[17] = '<img src="http://www.hspn.net/images/clipart/THECross.jpg" align="top" width="260" height="99" alt="Amazing Grace! Jesus Paid it All!" title="Amazing Grace! Jesus Paid it All!">';
//adsF[18] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4253" target= _new"><img src="http://www.hspn.net/images/Advertisers/myhomeschoolrewardsAdJuly2008.jpg" width="260" height="99"  align="left" alt="Use giftcards for everyday purchases and get cash back" title="Use giftcards for everyday purchases and get cash back"></a><font face="arial" size="2">'
//adsF[19] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4421" target= "_new"><img src="http://www.hspn.net/images/advocare/slam.jpg" align="left" height="95" width="110" alt="SLAM&#174 - Sugar-Free Energy Drink" title="SLAM&#174 - Sugar-Free Energy Drink" border="0"></a>';
//adsF[20] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4234" target= "_new"><img src="http://www.hspn.net/images/Advocare/e_drew_brees2.jpg" height="90" width="260" height="99" align="left"></a>';
//adsF[21] = '<a href="http://www.hspn.net/ADV/Landing.asp?id=4333" target= "_new" alt="This company helps your team raise money for tournament and travel expenses ..."><img alt="Want to get the funds to get you to the tournament? Check these guys out!" src="http://www.hspn.net/Images/EastCoast/Sponsors/mysportsdream.gif" width="260" height="99" align=left border="0"></a></font>';
//adsF[22] = '<img src="http://www.hspn.net/images/clipart/createawebsite.jpg" align="left" height="99" width="260" alt="Let HSPN Create Your Team Web-site" title="Let HSPN Create Your Team Web-site">';
//adsF[23] = '<font size="1"><a href="http://www.hspn.net/ADV/Landing.asp?id=4234" target= "_new"><img src="http://www.hspn.net/images/Advocare/e_michael_smith.jpg" height="99" width="260" align="left"></a>';
//adsF[24] = '<font size="2"><a href="http://www.hspn.net/ADV/Landing.asp?id=4233" target= "_new"><img src="http://www.hspn.net/images/Magnets/eagle.jpg" height="99" width="260" align="left" border="0" alt="Customized Car Magnets  Homeschool Friendly Pricing  We put the FUN back in fundraising. Full color, Custom Shapes" title="Customized Car Magnets  Homeschool Friendly Pricing  We put the FUN back in fundraising. Full color, Custom Shapes"></a>';
var aSlideShow = new Array;
// Developing  News
//aSlideShow[0]='<div style="width:250px; height:200px;"><font face="Garamond,Arial" style=font-size:18pt;"><center><b>Developing News....</b></center></font><font face="Verdana" style="font-size:12pt; color:red;">'; 
//aSlideShow[0] =   aSlideShow[0]+ '<center><b>Coming out in our next newsletter....</b></center></font><p><font face="Bookman Old Style" style=font-size:12pt;"><b>HSPN is bringing College Scouts to You.... and Vice-Versa...</b></center>';
//aSlideShow[0] =   aSlideShow[0]+ '</font><br><img src="http://www.hspn.net/images/EastCoast/2010/ncsa-logo-sm.jpg" width="200" align="left"><font face="Arial" style=font-size:10pt;">HSPN is now affiliated with the <b>National Collegiate Scouting ';
//aSlideShow[0] =   aSlideShow[0]+ 'Association </b>, the largest college recruiting company in the nation.  Details coming....<br><br><br></p><hr><p><font face="Bookman Old Style" style=font-size:12pt;"><b>Do You Have a Coaching Certification?</b></center>';
//aSlideShow[0] =   aSlideShow[0]+ '</font><br><img src="http://www.hspn.net/images/EastCoast/2010/OnCourtPlayerDevelopment1.jpg" width="200" align="left"><font face="Arial" style=font-size:10pt;">';
//aSlideShow[0] =   aSlideShow[0]+ 'Another new partner, <b>On Court Player Development</b>, can provide you with a <U>coaching certification program</U> that will prepare you to coach your team like never before.  Their Skills2Score Team System provides you with access to their <B><I>Advanced Skills and Fundamentals Online ';
//aSlideShow[0] =   aSlideShow[0]+ 'Certification Course</I> ... <br><br><br></p><hr><p><font face="Bookman Old Style" style=font-size:12pt;"><b>Get Ready for East Coast 2010</b><a href="http://www.hspn.net/events/eastcoasttourney2010.asp"> 2010 web site </a></font></p></div>';

// Developing  News
//aSlideShow[1]= aSlideShow[0];
// n-Perspective
//aSlideShow[2]='<a href="#gPlayerStats"><img src="http://hspn.net/images/marketing/nPerspective.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"><br><font size=2></a><b>The most in-depth Player Stats portfolio for homeschool sports.  And it\'s *FREE!* Check out <a href="#gPlayerStats">n-Perspective Stat Manager </a>for Football, Volleyball and Soccer </b></font><br>';


// EastCoast2010 logo
aSlideShow[0] = '<a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><img src="http://www.hspn.net/Images/EastCoast/2010/Champions/Girls4AChamps.jpg" alt="" title= "" width="' + intLeftAlley + '" align="top" hspace="2" border=0 height="200"></a><br><font size=2><a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp">East Coast Homeschool Basketball Tournament</a></b></font>';
// Baden ball logo
//aSlideShow[1]='<a href="http://www.eastcoasttournament.com"><img src="http://www.hspn.net/images/eastcoast/2010/badenlogoball2.jpg" alt="" title= "" width="' + intLeftAlley + '" align="top" hspace="2" border=0 height="200"></a><br><font size=1><b>Baden ("bah-din") is the Official Basketball of the 2010 East Coast Tournament <a href="http://www.eastcoasttournament.com"> details...</a></b></font>';
// CaptainU
//aSlideShow[1]='<a href="http://www.captainu.com"><img src="http://www.hspn.net/images/eastcoast/2010/captainu.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=1><center><b>Check out CaptainU.com <a href="http://www.captainu.com"> info...</a></b></center></font>';
//aSlideShow[2]='<a href="http://www.hspn.net/Events/eastcoasttourney2010.asp"><IMG src="http://www.hspn.net/Images/EastCoast/2010/Champions/Girls4AChamps.jpg"  alt="" title="" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=1><b><center>At the  East Coast Championships, Division champs receive their championship banner. <a href="http://www.hspn.net/Events/eastcoasttourney2010.asp"><b>tournament web site...</b></a></center></font>';
// Merry CHRISTmas
//aSlideShow[3]='<img src="http://www.hspn.net/images/LG_XLWreath.gif" alt="" title= "" width="' + intLeftAlley + '" align="top" hspace="2" border=0 height="200"></a><br><font size=1><center><b>Merry CHRISTmas from HSPN!</b></center></font>';

// soccer tournament
aSlideShow[1] = '<a href="/ADV/Landing.asp?id=4900&dest=/Articles/fullstory.asp%3Fid=5229"><img src="http://www.hspn.net/images/2008/Soccer (12).jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=2><b>Coming in Oct 2010...Homeschool Championships at the Bluff <a href="/ADV/Landing.asp?id=4900&dest=/Articles/fullstory.asp%3Fid=5229">details...</b></a></font>';

// Flag
aSlideShow[2]='<IMG src="http://www.hspn.net/Images/clipart/Flag.jpg"  alt="" title="" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0><br><font size=1><b><center>Thank You FATHER for our country.</b></center></font>';

// Bryan College
aSlideShow[3]='<a href="http://www.bryan.edu"><img src="http://www.hspn.net/images/eastcoast/sponsors/Adm-2010-HSPN-web-banner.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=1><b></b></font>';
// football
//aSlideShow[5]='<a href="../Articles/default.asp?a=football"><img src="http://www.hspn.net/images/football/maccwilson.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=1><b>Homeschool Football News, Team Standings, Stats, etc <a href="../Articles/default.asp?a=football"> details...</a></b></font>';

// volleyball
aSlideShow[4] = '<a href="/ADV/Landing.asp?id=5091&dest=/Articles/fullstory.asp%3Fid=5229"><img src="http://www.hspn.net/images/Volleyball/VolleyballCrownAthletics.JPG"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=2><b>Upcoming Homeschool Volleyball Tournament <a href="/ADV/Landing.asp?id=5091&dest=/Articles/fullstory.asp%3Fid=5229">details...</b></a>';

// cheerleading
//aSlideShow[7]='<img src="http://www.hspn.net/images/2006/SouthRegion/knightscheergym.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0>';

//GUIG
aSlideShow[5]='<a href="http://www.growingupingrace.com"><img src="http://www.hspn.net/Images/Sponsors/GUIGlogo.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=1></a><br><font size=1></font><br>';

// Golf
//aSlideShow[9]='<a href="http://www.hspn.net/Articles/default.asp?a=golf"><img src="http://www.hspn.net/Images/Golf/HSPNGolfJr.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><a href="http://www.kuyper.edu"><font size=1><b>Golf Events for Homeschoolers!</b></a></font>';

// Baden logo
//aSlideShow[10]='<a href="http://www.eastcoasttournament.com"><img src="http://www.hspn.net/images/eastcoast/2010/badenlogo.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=1><b>Baden ("bah-din") Basketball is the Official Basketball of the East Coast Homeschool Basketball Tournament <a href="http://www.eastcoasttournament.com"> details...</a></b></font>';

// Girls 4A
aSlideShow[6] = '<a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><img src="http://www.hspn.net/images/eastcoast/2010/Champions/Boys7AChamps.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=2><b><a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp">East Coast Homeschool Basketball Tournament</b></a></font>';
// testimonial

aSlideShow[7] = '<a href="/ADV/Landing.asp?id=5225&dest=/Articles/fullstory.asp%3Fid=5225"><img src="http://www.hspn.net/Images/Equestrian/hsequestrian.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=2><b><a href="/ADV/Landing.asp?id=5225&dest=/Articles/fullstory.asp%3Fid=5225">Equestrian Opportunities for Homeschoolers</b></a></font>';
// testimonial

aSlideShow[8] = '<a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><IMG src="http://www.hspn.net/images/eastcoast/2010/Feedback/2010Watermarkfadetesttestm1.jpg"  alt="" title="" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=2><a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><b>East Coast Homeschool Basketball Tournament</b></a></font>';
// slam dunk
aSlideShow[9] = '<a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><img src=http://www.hspn.net/images/eastcoast/2010/SlamDunk/slamdunkiso.jpg width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=2><a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><b>East Coast Homeschool Basketball Tournament</b></a></font>';
// The National Scoreboard
aSlideShow[10] = '<a href="/ADV/Landing.asp?id=5293&dest=/HSPN247/"><img src="http://www.hspn.net/images/newsletter/TNS.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=2><b>&nbsp;&nbsp;National Homeschool Scoreboard <a href="/HSPN247/"><b>info...</b></a></font>';
// alumni
aSlideShow[11] = '<a href="/ADV/Landing.asp?id=4904&dest=/Articles/fullstory.asp%3Fid=4904"><img src="http://www.hspn.net/images/2009/2009AlumniGame.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2"  border=0></a><br><font size=2><b><a href="/ADV/Landing.asp?id=4904&dest=/Articles/dfullstory.asp%3Fid=4904">Alumni News</b></a></font>';

// Here 4 You
//aSlideShow[16]='<a href="http://www.hspn.net/showcase/?showcase=11" target=_new><img src="http://www.hspn.net/Images/theShowCase/LindenfogProductions/here4you.JPG" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0><br><font size=1><b><center>Here 4 You - Funding and Consulting</center></b></a></font>';

//Vines Center
aSlideShow[12] = '<a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><IMG src="http://www.hspn.net/Images/EastCoast/Marketing/VinesFloor.jpg"  alt="Home of the East Coast Homeschool Basketball Championships"  title="Home of the East Coast Homeschool Basketball Championships" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=2><a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><b>East Coast Homeschool Basketball Championships</b></a></font>';
// All-Tournament
aSlideShow[13] = '<a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><img src="http://www.hspn.net/images/eastcoast/2010/AllTournamentBoys/BoysAllTournamentTeam.jpg"  alt="All-Star Girls Team from the 2009 East Coast Homeschool Basketball Championships" title= "All-Star Girls Team from the 2009 East Coast Homeschool Basketball Championships" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=2><a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><b>East Coast Homeschool Basketball Championships</b></a></font>';

// Workshops
aSlideShow[14]='<img src="http://www.hspn.net/images/Seminars/Workshop2008.jpg" alt="HSPN delivers a variety of workshops" title= "HSPN delivers a variety of workshops" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0><br><font size=2><b>&nbsp;&nbsp;HSPN\'s next workshop is... </b></font>';

// Soccer, little kds
//aSlideShow[20]='<img src="http://www.hspn.net/images/2005/SpringSoccer/u8BlueatValleyCampaign.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0>';
// Softball
//aSlideShow[21]='<img src="http://www.hspn.net/images/Texas/Satch-Champs.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0>';

// East Coast Testimonial
aSlideShow[15] = '<a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><IMG src="http://www.hspn.net/images/eastcoast/2010/Feedback/2010Watermarkfadetesttestm2.jpg"  alt="" title="" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=2><a href="/ADV/Landing.asp?id=5288&dest=/Events/EastCoastTourney2010.asp"><b>East Coast Homeschool Basketbal Tournament</b></a></font>';

// n-Perspective
aSlideShow[16] = '<a href="/ADV/Landing.asp?id=4902&dest=/Articles/fullstory.asp%3Fid=4902"><img src="http://hspn.net/images/marketing/nPerspective.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=2><a href="/ADV/Landing.asp?id=4902&dest=/Articles/fullstory.asp%3Fid=4902"><b>*FREE* Player Stats Portfolio</b></a></font>';

// My Sports Dream
aSlideShow[17] = '<a href="/ADV/Landing.asp?id=4907&dest=/Articles/fullstory.asp%3Fid=4907"><img src="http://www.hspn.net/Images/EastCoast/2010/mySportsDream.gif" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=2><b><a href="/ADV/Landing.asp?id=4907&dest=/Articles/fullstory.asp%3Fid=4907">Easy Fundraising for Teams.</b></a></font>';

// OBlock Books
//aSlideShow[25]='<a href="http://www.oblockbooks.com"><img src="http://www.hspn.net/images/sponsors/OblockBookslogo4.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><font size=1></font>';

// Kuper College
aSlideShow[18]='<a href="http://www.kuyper.edu"><img src="http://www.hspn.net/Images/EastCoast/Sponsors/Casey & Crowd.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><a href="http://www.kuyper.edu"><font size=1><b>Kuyper College</b></a></font>';

// Judson College
aSlideShow[19] = '<a href="http://www.judsonu.edu"><img src="http://www.hspn.net/Images/EastCoast/Sponsors/JudsonHSPN.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><a href="http://www.judsonu.edu"><font size=1><b>Judson University</b></a></font>';

// Cornerstone Payments
aSlideShow[20] = '<a href="/Articles/fullstory.asp?id=5328"><img src="http://www.hspn.net/images/sponsors/cornerstonepaymentlogo.gif" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><a href="/Articles/fullstory.asp?id=5328"><font size=2><b>Cornerstone Payments System</b></a></font>';

// Sports Virtues
//aSlideShow[21] = '<a href="/Articles/fullstory.asp?id=5324"><img src="http://www.hspn.net//images/sponsors/fritzknapp.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><a href="/Articles/fullstory.asp?id=5324"><font size=2><b>The Book of Sports Virtues</b></a></font>';
aSlideShow[21] = '<a href="http://www.oblockbooks.com"><img src="http://www.hspn.net/images/sponsors/OblockBookslogo4.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br>';

// Uniforms
aSlideShow[22] = '<a href="/Articles/fullstory.asp?id=5316"><img src="http://www.hspn.net/images/sponsors/aayp.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><a href="/Articles/fullstory.asp?id=5316"><font size=2><b>GREAT Uniforms</b></a></font>';

// Team locator
aSlideShow[23] = '<a href="/ADV/Landing.asp?id=5294&dest=/Teamlocator/"><img src="http://www.hspn.net//images/usamapLocator.jpg" alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="top" hspace="2" border=0></a><br><a href="/Articles/fullstory.asp?id=5316"><font size=2><b>Find a Team, Post Your Team</b></a></font>';

//aSlideShow[13]='<img src="http://www.hspn.net/images/EastCoast/PhotoGallery/BoysV5A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[14]='<img src="http://www.hspn.net/images/EastCoast/PhotoGallery/18UGirlsWinners.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[15]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/15UGirlsWinners.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[16]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/12UBoysWinners.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[17]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/15UBoysWinners.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[18]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/Luncheon.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[19]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV3A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[20]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV2A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[21]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV1A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[22]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsJV1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[23]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV4A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[24]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV3A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[25]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV2A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[26]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV1A1st.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[27]='<img src="http://www.hspn.net/images/2008/2008StateChamps.jpg"  alt="" title= "" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[3]='<img src="http://www.hspn.net/images/2008/Soccer (10).jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';;
//aSlideShow[5]='<img src="http://www.hspn.net/images/2008/Soccer (21).jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[8]='<img src="http://www.hspn.net/images/EastCoast/Marketing/VinesFloor.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[12]='<IMG alt="Home of the East Coast Homeschool Basketball Championships" src="http://www.hspn.net/Images/EastCoast/Marketing/2009EastCoastLogo0.jpg"  width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[13]='<img src="http://www.hspn.net/images/Investment/CoachDigges.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[18]='<img src="http://www.hspn.net/images/2008/KellynFlamesAfter1Kpoints.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[19]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/CoachesPickupGameLead.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[20]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/CoachesPickupGame3.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[24]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/18UBoysWinners.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[25]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/AdultsWinners.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[26]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/Luncheon3.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[28]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/Luncheon2.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[30]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV3A2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[31]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV3A2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[32]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV3A3rd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[34]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV2A2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[36]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsV1A2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[38]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsJV2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[39]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/GirlsJV3rd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[40]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV5A1st.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[41]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV5A2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[42]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV5A3rd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[44]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV4A2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[45]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV4A3rd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[47]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV3A2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[48]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysV3A3rd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[50]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/Boys_V_2A_2nd_CHENWhite 2717.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[52]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysVA2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[53]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysVA3rd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[51]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/BoysJV3A1st.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';
//aSlideShow[52]='<img src="http://www.hspn.net/Images/EastCoast/PhotoGallery/Boys_JV_3A_2nd.jpg" width="' + intLeftAlley + '" height="' + imgHeight + '" align="left" hspace="2">';






var aCaptions = new Array;
var majStyle40 =   ' style= "font-face:Credit Valley, Arial; font-size: 16pt; color:#455342;"'    //#616e65
var minorStyle40 = ' style= "font-face:Bookman OldStyle, Arial;font-size: 12pt; color:#455342;"'   //#4e5543

var majStyle41 =   ' style= "font-face:Credit Valley, Arial; font-size: 16pt; color:#f24a26;"'
var minorStyle41 = ' style= "font-face:Bookman OldStyle, Arial;font-size: 12pt; color:#f24a26;"'  //#515390

var majStyle42 =   ' style= "font-face:Credit Valley, Arial; font-size: 16pt; color:#343932;"'
var minorStyle42 = ' style= "font-face:Bookman OldStyle, Arial;font-size: 12pt; color:#343932;"'

var majStyle43 =   ' style= "font-face:Credit Valley, Arial; font-size: 16pt; color:#3f2f22;"'
var minorStyle43 = ' style= "font-face:Bookman OldStyle, Arial;font-size: 12pt; color:#3f2f22;"'

var majStyle44 =   ' style= "font-face:Credit Valley, Arial; font-size: 16pt; color:#1c1a1f;"'
var minorStyle44 = ' style= "font-face:Bookman OldStyle, Arial;font-size: 12pt; color:#1c1a1f;"'

var majStyle45 =   ' style= "font-face:Credit Valley, Arial; font-size: 16pt; color:#343932;"'
var minorStyle45 = ' style= "font-face:Bookman OldStyle, Arial;font-size: 12pt; color:#343932;"'


// image #40
aCaptions[0] = '<a href="http://www.hspn.net/default2008a.asp" ' + majStyle40 + '><b>Ways to <br>Get Started </b></a>';
aCaptions[0] = aCaptions[0] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle40 + '>Start Your Own <br>Sports Program</a>';
aCaptions[0] = aCaptions[0] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle40 + '>Resource: "Getting <br>Started" Handbook</a>';

// image #41
aCaptions[1] = '<a href="http://www.hspn.net/default2008a.asp" ' + majStyle41 + '><b>Ways to <br>Get Started </b></a>';
aCaptions[1] = aCaptions[1] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle41 + '>Get Your <br> Kids Involved </a>';
aCaptions[1] = aCaptions[1] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle41 + '>Attend a Summer <br>Workshop</a>';

// image #42
aCaptions[2] = '<a href="http://www.hspn.net/default2008a.asp"' + majStyle42 + '><b>Our Team <br>Locator System </b></a> ';
aCaptions[2] = aCaptions[2] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle42 + '>Find Any Team <br>in the USA</a>';
aCaptions[2] = aCaptions[2] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle42 + '>Post a Note to <br>a Coach or <br>Sports Leader</a>';

// image #43 - 40
aCaptions[3] = '<a href="http://www.hspn.net/default2008a.asp" ' + majStyle43 + '><b>Our Team <br>Locator System </b></a> ';
aCaptions[3] = aCaptions[3] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle43 + '>Post Your <br>Team Information</a>';
aCaptions[3] = aCaptions[3] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle43 + '>Post Your <br>Game Schedules</a>';

// image #44 
aCaptions[4] = '<a href="http://www.hspn.net/default2008a.asp" ' + majStyle44 + '><b>Experience <br>the Opportunities </b></a>';
aCaptions[4] = aCaptions[4] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle44 + '>Homeschool Tournaments and <br>Championships</a>';
aCaptions[4] = aCaptions[4] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle44 + '>Sports Camps<br>for Homeschoolers</a>';

//#image #45
aCaptions[5] = '<a href="http://www.hspn.net/default2008a.asp" ' + majStyle45 + '><b>Experience <br>the Opportunities </b></a>';
//aMainCaptions[5] = aMainCaptions[5] + '<br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle3 + '>Tournaments and Sporting Events</a>';
//aMainCaptions[5] = aMainCaptions[5] + '<br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle3 + '>Sports Camps</a>';
aCaptions[5] = aCaptions[5] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle45 + '>HSPN Team <br>Membership</a>';
aCaptions[5] = aCaptions[5] + '<br><br><br><a href="http://www.hspn.net/default2008a.asp" ' + minorStyle45 + '>General Liability-<br>Medical Insurance</a>';


//JavaScript Banner Ad Rotator version 2.1 - last modified 16 November 2000
//Obtained from http://www.brettb.com/js_banner_ad_rotator.asp
//Email comments or suggestions using the form at http://www.brettb.com/Contact.asp
//If you want a version of this script that will open links in a new browser window
//then please visit http://www.winnershtriangle.com/w/Products.JavaScriptBannerAdRotator.asp


function InitializeSlideshow() 
{
	//Determine the browser name and version
	//The script will only work on Netscape 3+ and Internet Explorer 4+
	var BrowserType = navigator.appName;	
	var BrowserVersion = parseInt(navigator.appVersion);

	if (BrowserType == "Netscape" && (BrowserVersion >= 3)) 
	{
		IsValidBrowser = true;
		//alert(IsValidBrowser);

	}

	if (BrowserType == "Microsoft Internet Explorer" && (BrowserVersion >= 4)) 
	{
		IsValidBrowser = true;

	}
	if (IsValidBrowser) 
	{
		document.TimerObject = setTimeout("ChangeImage('',maxMainSlideshowImageNum,startMainSlideshowImageNum, refreshMainSlideShowImage)", 0);
    document.TimerObject = setTimeout("ChangeImagea('',maxAds, startAd)", 0);

	}
}

function ChangeImage(preF, maxImageNum, startImageNum, refresh)
{
	//setMainSlideshow();
	
	if (IsValidBrowser)
		{
			// ----------- call to change slide show image ----
			//alert(MainSlideshowImageNum+','+ctrlMainLooping+','+imageWithinSlideShowPanelCounter+','+selectedCaptionNum);
			showFlashFilmStrip(MainSlideshowImageNum , selectedCaptionNum, refreshMainSlideShowImage);
			selectedCaptionNum++;
			MainSlideshowImageNum++;			
			 if (MainSlideshowImageNum > maxMainSlideshowImageNum)	
				{
					MainSlideshowImageNum = 0;
					selectedCaptionNum = 0;
				}
			if (adToggle > 0)
				{
				document.TimerObject = setTimeout("ChangeImagea('',maxAds, startAd)", 0);
				adToggle = 0;
				}
			else
				{
				adToggle = 1;
				}
			document.TimerObject = setTimeout("ChangeImage('', maxMainSlideshowImageNum, startMainSlideshowImageNum)", DisplayInterval);
		}
}

function ChangeImagea(preF, maxI, initIndex) {

	if (IsValidBrowser)
	 {
		Adcounter = Adcounter + 1;
		if (Adcounter > maxI)
		{
			Adcounter = initIndex;
		}
		//showAda(Adcounter);
	}
}

function showAda(d)
{
oLayer = eval('eltAds0');
if (IsValidBrowser)
{
		oLayer.innerHTML = adsF[d];
		oLayer.style.visibility = "visible";
}
}

function showFlash(d,o,refresh)
{
	//alert(d +','+o+','+refresh);
	//document.getElementById("MainCaptions").style.visibility="hidden";
	//document.getElementById("MainCaptions").style.backgroundColor="transparent";
	//document.getElementById("MainCaptions").style.left="5px";
	//document.getElementById("MainCaptions").style.top="485px";
	//document.getElementById("MainCaptions").style.width="280px";
	//document.getElementById("MainCaptions").style.position="absolute";

	//document.getElementById("Slideshow").style.visibility="hidden";
	//document.getElementById("Slideshow").style.backgroundColor="transparent";
	//document.getElementById("Slideshow").style.left="15px";
	//document.getElementById("Slideshow").style.top= "285px";
	//document.getElementById("Slideshow").style.width="280px";
	//document.getElementById("Slideshow").style.position="absolute";

	document.getElementById("Slideshow").style.visibility="hidden";
	document.getElementById("Slideshow").style.backgroundColor="transparent";
	document.getElementById("Slideshow").style.left="520px";
	document.getElementById("Slideshow").style.top= "206px";
	document.getElementById("Slideshow").style.width="500px";
	document.getElementById("Slideshow").style.position="absolute";

	oSlideShow = eval('eltSlideShow');
	oCaptions = eval('eltCaptions');

	if (IsValidBrowser)
	{
		//setMainSlideshow();
		//oCaptions.style.visibility = "visible";
		//oCaptions.innerHTML = '<p>Photo<br><br>is<br><br>Loading.....</p>';

		if (refresh)
		{
			//oSlideShow.innerHTML = '<p>Photo<br><br>is<br><br>Loading.....</p>';
			oSlideShow.style.visibility = "visible";
			oSlideShow.innerHTML = aSlideShow[d];
			oSlideShow.style.visibility = "visible";
		}
		//oCaptions.style.visibility = "visible";
		//oCaptions.innerHTML = aCaptions[o];
    //document.getElementById("MainCaptions").style.visibility="visible";
	}
}

function showFlashFilmStrip(d,o,refresh)
{
	//alert(d +','+o+','+refresh);

 	document.getElementById("filmstrip1").style.visibility="hidden";
	document.getElementById("filmstrip1").style.backgroundColor="transparent";
	document.getElementById("filmstrip1").style.left="0px";
	if (gBrowserType == "Netscape") {
	    document.getElementById("filmstrip1").style.top = "1100px";
	}
	else {
	    document.getElementById("filmstrip1").style.top = "1260px";
	}
	document.getElementById("filmstrip1").style.width="248px";
	document.getElementById("filmstrip1").style.position="absolute";

	document.getElementById("filmstrip2").style.visibility="hidden";
	document.getElementById("filmstrip2").style.backgroundColor="transparent";
	document.getElementById("filmstrip2").style.left="250px";
	if (gBrowserType == "Netscape") {
	    document.getElementById("filmstrip2").style.top = "1100px";
	}
	else {
	    document.getElementById("filmstrip2").style.top = "1260px";
	}
	document.getElementById("filmstrip2").style.width="248px";
	document.getElementById("filmstrip2").style.position="absolute";

	document.getElementById("filmstrip3").style.visibility="hidden";
	document.getElementById("filmstrip3").style.backgroundColor="transparent";
	document.getElementById("filmstrip3").style.left="500px";
	if (gBrowserType == "Netscape") {
	    document.getElementById("filmstrip3").style.top = "1100px";
	}
	else {
	    document.getElementById("filmstrip3").style.top = "1260px";
	}
	document.getElementById("filmstrip3").style.width="248px";
	document.getElementById("filmstrip3").style.position="absolute";

	document.getElementById("filmstrip4").style.visibility="hidden";
	document.getElementById("filmstrip4").style.backgroundColor="transparent";
	document.getElementById("filmstrip4").style.left="750px";
	if (gBrowserType == "Netscape") {
	    document.getElementById("filmstrip4").style.top = "1100px";
	}
	else {
	    document.getElementById("filmstrip4").style.top = "1260px";
	}
	document.getElementById("filmstrip4").style.width="248px";
	document.getElementById("filmstrip4").style.position="absolute";

	oSlideShow = eval('eltSlideShow');
	oCaptions = eval('eltCaptions');


	oFilmStrip1 = eval('eltFilmStrip1');
	oFilmStrip2 = eval('eltFilmStrip2');
	oFilmStrip3 = eval('eltFilmStrip3');
	oFilmStrip4 = eval('eltFilmStrip4');



	if (IsValidBrowser)
	{
		//setMainSlideshow();
		//oCaptions.style.visibility = "visible";
		//oCaptions.innerHTML = '<p>Photo<br><br>is<br><br>Loading.....</p>';

		if (refresh)
		{
			//oSlideShow.innerHTML = '<p>Photo<br><br>is<br><br>Loading.....</p>';
			//oSlideShow.style.visibility = "visible";
			//oSlideShow.innerHTML = aSlideShow[d];
			//oSlideShow.style.visibility = "visible";

			oFilmStrip1.innerHTML = aSlideShow[d];
			if (ffTest < 0) {oFilmStrip1.style.zIndex = -1;}
			oFilmStrip1.style.visibility = "visible";

			if (d+1 > maxMainSlideshowImageNum) 
			{
				oFilmStrip2.innerHTML = aSlideShow[0];
				if (ffTest < 0) {oFilmStrip2.style.zIndex = -1;}
				oFilmStrip2.style.visibility = "visible";
			}
			else
			{
				oFilmStrip2.innerHTML = aSlideShow[d+1];
				if (ffTest < 0) {oFilmStrip2.style.zIndex = -1;}
				oFilmStrip2.style.visibility = "visible";
			}

			if(d+2 > maxMainSlideshowImageNum )
			{
				oFilmStrip3.innerHTML = aSlideShow[0];
				if (ffTest < 0) {oFilmStrip3.style.zIndex = -1;}
				oFilmStrip3.style.visibility = "visible";
			}
			else
			{
				oFilmStrip3.innerHTML = aSlideShow[d+2];
				if (ffTest < 0) {oFilmStrip3.style.zIndex = -1;}
				oFilmStrip3.style.visibility = "visible";
			}

			if(d+3 > maxMainSlideshowImageNum )
			{	
				oFilmStrip4.innerHTML = aSlideShow[0];
				if (ffTest < 0) {oFilmStrip4.style.zIndex = -1;}
				oFilmStrip4.style.visibility = "visible";
			}
			else
			{
				oFilmStrip4.innerHTML = aSlideShow[d+3];
				if (ffTest < 0) {oFilmStrip4.style.zIndex = -1;}
				oFilmStrip4.style.visibility = "visible";
			}
		}

		//oCaptions.style.visibility = "visible";
		//oCaptions.innerHTML = aCaptions[o];
    //document.getElementById("MainCaptions").style.visibility="visible";
	}
}


function setMainSlideshow() {
 if (MainSlideshowImageNum = maxMainSlideshowImageNum)	
	{
		MainSlideshowImageNum = 0;
		selectedCaptionNum = 0;
	}
}
function setSlideShowDefaults(val)
{
	ctrlMainLooping = val;
	ctrlMainPanelLooping =0;
	offsetMainSlideShow = 0;
	imageWithinSlideShowPanelCounter =0;
	MainSlideshowImageNum = 40+(6*(val-1));
	startMainSlideshowImageNum = MainSlideshowImageNum;
	selectedCaptionNum = 6*(val-1);
	refreshMainSlideShowImage = true;

}
