if(window.attachEvent)
window.attachEvent("onload",setListeners);

function setListeners()
{
	inputList = document.getElementsByTagName("INPUT");
	for(i=0;i<inputList.length;i++)
	inputList[i].attachEvent("onpropertychange",restoreStyles);
	selectList = document.getElementsByTagName("SELECT");
	for(i=0;i<selectList.length;i++)
	selectList[i].attachEvent("onpropertychange",restoreStyles);
}

function restoreStyles()
{
	if(event.srcElement.style.backgroundColor != "")
	event.srcElement.style.backgroundColor = "";
}



function topnavOver(item) 
{

	item.style.border='1px #400f0f solid';
	item.style.backgroundColor='#8e0009';
	item.style.cursor='hand';
	
}

function topnavOut(item) 
{
	item.style.border='1px #8c8c8c solid';
	item.style.backgroundColor='';
}

function leftnavOver(item, indt, o, op) 
{

	if (o == 0 ){
		if (indt == 0){
			item.style.backgroundColor='#8E0009';
			item.style.cursor='hand';
		} else {
			item.style.backgroundColor='#8E0009';
			item.style.cursor='hand';
		}
	} else {
		item.style.cursor='hand';
	}
}

function leftnavOut(item, indt, o, op) 
{
	if (o == 0 ){
		if (indt == 0){
			item.style.backgroundColor='transparent';
		} else {
			item.style.backgroundColor='#7E564C';
		}
	} else {
		item.style.cursor='hand';
	}
}

function trackOver(item){
			item.style.backgroundColor='#8c8c8c';
			item.style.cursor='hand';
}

function trackOut(item){
			item.style.backgroundColor='transparent';
}

function featureOver(item){
			item.style.backgroundColor='#8c8c8c';
			item.style.cursor='hand';
			item.style.borderColor='white';
			item.style.color='white';
}

function featureOut(item){
			item.style.backgroundColor='transparent';
			item.style.borderColor='#8c8c8c';
			item.style.color='C9C9C9';
}