window.onload=function()
{
    nsidcLinkStyles();
    avhrrLinkStyles();
    // add other functions to be called onload below
   
    writeCaption();
    window.setTimeout('cycle();',6000);
    (loadbanners());
    //(urlswitch()); // is this supposed to be doing something? doesn't look like any links coded for images, so this isn't needed
}

function avhrrLinkStyles()
{
	var url = document.location.href;

// conditions for AVHRR navigation

// Overview-
	
	if(url.match(/\/avhrr\/index.html/))
	{
		document.getElementById("navAvhrrOverview").className = "secondarySiteNavActiveNoSubnav";
		document.getElementById('navAvhrrOverview').innerHTML = 'Overview';
	}

	
// Data Summaries
	if(url.match(/data_summaries.html/))
	{
		document.getElementById("navAvhrrDataSummaries").className = "secondarySiteNavActiveNoSubnav";
		document.getElementById('navAvhrrDataSummaries').innerHTML = 'Data Summaries';
	}

	
// Order Data
	
	if(url.match(/order_data.html/))
	{
		document.getElementById("navAvhrrOrder").className = "secondarySiteNavActiveNoSubnav";
		document.getElementById('navAvhrrOrder').innerHTML = 'Order Data';
	}
		
// if none of these conditions, do nothing
	
	else {}
	
}