// JavaScript Document

// header menu
function menuOn(id){
	if(current_page){
		document.getElementById('sub-menu'+current_page).style.display='none';
	}
	document.getElementById('menu'+id).style.visibility='hidden';
	document.getElementById('sub-menu'+id).style.display='block';
}
function menuOff(id){
	if(id != current_page){
		document.getElementById('menu'+id).style.visibility='visible';
	}
	document.getElementById('sub-menu'+id).style.display='none';
	if(current_page){
		document.getElementById('sub-menu'+current_page).style.display='block';
	}
}

// store locator
function chgMap(id){
	for(i=1; i<=16; i++){
		if(id != i){
			document.getElementById('store'+i).style.display='none';
			document.getElementById('storemenu'+i).style.color='#343434';
			document.getElementById('storemenu'+i).style.background='#FFFFFF url(images/arrow_off.gif) 11px 9px no-repeat';
		}
		else{
			document.getElementById('store'+i).style.display='block';
			document.getElementById('storemenu'+i).style.color='#FFFFFF';
			document.getElementById('storemenu'+i).style.background='#97b9c7 url(images/arrow_on.gif) 11px 9px no-repeat';
		}
	}
}

// Q & A
function qaOnOff(id, type){
	var disp = document.getElementById(id).style.display;
	if(disp == "block"){
		document.getElementById(id).style.display = "none";
		document.getElementById('T'+id).style.backgroundImage = "url(images/qa_arrow"+type+"a.gif)";
	}
	else{
		document.getElementById(id).style.display = "block";
		document.getElementById('T'+id).style.backgroundImage = "url(images/qa_arrow"+type+"b.gif)";
	}
}

// Whats new
function newsOnOff(id){
	var disp = document.getElementById(id).style.display;
	if(disp == "block"){
		document.getElementById(id).style.display = "none";
		document.getElementById('T'+id).style.backgroundImage = "url(images/news_arrow1a.gif)";
	}
	else{
		document.getElementById(id).style.display = "block";
		document.getElementById('T'+id).style.backgroundImage = "url(images/news_arrow1b.gif)";
	}
}

