
var acttb1 = true;
var acttb2 = false;
var acttb3 = false;
var acttb4 = false;
var acttb5 = false;
		
function hidediv(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.display = 'none';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.display = 'none';
		}
		else { // IE 4
			document.all.id.style.display = 'none';
		}
	}
}

function showdiv(id) {
	//safe function to show an element with a specified id
		  
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.display = "";
		
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.display = 'block';
		}
		else { // IE 4
			document.all.id.style.display = 'block';
		}
	}
}



/////////////////////////////////////////////
function ActiveTabText(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.color = '#666666';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.color = '#666666';
		}
		else { // IE 4
			document.all.id.style.color = '#666666';
		}
	}
}

function DeactiveTabText(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.color = '#666666';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.color = '#66666';
		}
		else { // IE 4
			document.all.id.style.color = '#666666';
		}
	}
}

///////////////////////////////////////////////////////


function ActiveTabLeft(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.background = 'url(ActiveLeftTab.jpg)';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.background = 'url(ActiveMiddleTab.jpg)';
		}
		else { // IE 4
			document.all.id.style.background = 'url(ActiveLeftTab.jpg)';
		}
	}
}

function DeactiveTabLeft(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.background = 'url(LeftTab.jpg)';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.background = 'url(LeftTab.jpg)';
		}
		else { // IE 4
			document.all.id.style.background = 'url(LeftTab.jpg)';
		}
	}
}

///////////////////////////////////////////////////////


function ActiveTabMid(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.background = 'url(ActiveMiddleTab.jpg)';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.background = 'url(ActiveMiddleTab.jpg)';
		}
		else { // IE 4
			document.all.id.style.background = 'url(ActiveMiddleTab.jpg)';
		}
	}
}

function DeactiveTabMid(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.background = 'url(MiddleTab.jpg)';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.background = 'url(MiddleTab.jpg)';
		}
		else { // IE 4
			document.all.id.style.background = 'url(MiddleTab.jpg)';
		}
	}
}


///////////////////////////////////////////////////////


function ActiveTabRight(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.background = 'url(ActiveRightTab.jpg)';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.background = 'url(ActiveRightTab.jpg)';
		}
		else { // IE 4
			document.all.id.style.background = 'url(ActiveRightTab.jpg)';
		}
	}
}

function DeactiveTabRight(id) {
	//safe function to hide an element with a specified id
	if (document.getElementById) { // DOM3 = IE5, NS6
		document.getElementById(id).style.background = 'url(RightTab.jpg)';
	}
	else {
		if (document.layers) { // Netscape 4
			document.id.background = 'url(RightTab.jpg)';
		}
		else { // IE 4
			document.all.id.style.background = 'url(RightTab.jpg)';
		}
	}
}


////////////////////////////////////////////////////
function ActivateTab(num){
	if (num == "1"){
		acttb1 = true;
		acttb2 = false;
		acttb3 = false;
		acttb4 = false;
		acttb5 = false;
		
		ActiveTabLeft('LeftTab1');
		ActiveTabMid('MidTab1');
		ActiveTabRight('RightTab1');
		ActiveTabText('Tab1Text');
		showdiv('TabBody1');
		
		DeactiveTabLeft('LeftTab2');
		DeactiveTabMid('MidTab2');
		DeactiveTabRight('RightTab2');
		DeactiveTabText('Tab2Text');
		hidediv('TabBody2');
		
		DeactiveTabLeft('LeftTab3');
		DeactiveTabMid('MidTab3');
		DeactiveTabRight('RightTab3');
		DeactiveTabText('Tab3Text');
		hidediv('TabBody3');
		
		DeactiveTabLeft('LeftTab4');
		DeactiveTabMid('MidTab4');
		DeactiveTabRight('RightTab4');
		DeactiveTabText('Tab4Text');
		hidediv('TabBody4');
		
		//DeactiveTabLeft('LeftTab5');
		//DeactiveTabMid('MidTab5');
		//DeactiveTabRight('RightTab5');
		//DeactiveTabText('Tab5Text');
		//hidediv('TabBody5');
	}
	if (num == "2"){
		acttb1 = false;
		acttb2 = true;
		acttb3 = false;
		acttb4 = false;
		acttb5 = false;
		
		ActiveTabLeft('LeftTab2');
		ActiveTabMid('MidTab2');
		ActiveTabRight('RightTab2');
		ActiveTabText('Tab2Text');
		showdiv('TabBody2');
		
		DeactiveTabLeft('LeftTab1');
		DeactiveTabMid('MidTab1');
		DeactiveTabRight('RightTab1');
		DeactiveTabText('Tab1Text');
		hidediv('TabBody1');
		
		DeactiveTabLeft('LeftTab3');
		DeactiveTabMid('MidTab3');
		DeactiveTabRight('RightTab3');
		DeactiveTabText('Tab3Text');
		hidediv('TabBody3');
		
		DeactiveTabLeft('LeftTab4');
		DeactiveTabMid('MidTab4');
		DeactiveTabRight('RightTab4');
		DeactiveTabText('Tab4Text');
		hidediv('TabBody4');
		
		//DeactiveTabLeft('LeftTab5');
		//DeactiveTabMid('MidTab5');
		//DeactiveTabRight('RightTab5');
		//DeactiveTabText('Tab5Text');
		//hidediv('TabBody5');
	}
	if (num == "3"){
		acttb1 = false;
		acttb2 = false;
		acttb3 = true;
		acttb4 = false;
		acttb5 = false;
		
		ActiveTabLeft('LeftTab3');
		ActiveTabMid('MidTab3');
		ActiveTabRight('RightTab3');
		ActiveTabText('Tab3Text');
		showdiv('TabBody3');
		
		DeactiveTabLeft('LeftTab2');
		DeactiveTabMid('MidTab2');
		DeactiveTabRight('RightTab2');
		DeactiveTabText('Tab2Text');
		hidediv('TabBody2');
		
		DeactiveTabLeft('LeftTab1');
		DeactiveTabMid('MidTab1');
		DeactiveTabRight('RightTab1');
		DeactiveTabText('Tab1Text');
		hidediv('TabBody1');
		
		DeactiveTabLeft('LeftTab4');
		DeactiveTabMid('MidTab4');
		DeactiveTabRight('RightTab4');
		DeactiveTabText('Tab4Text');
		hidediv('TabBody4');
		
		//DeactiveTabLeft('LeftTab5');
		//DeactiveTabMid('MidTab5');
		//DeactiveTabRight('RightTab5');
		//DeactiveTabText('Tab5Text');
		//hidediv('TabBody5');
	}
	if (num == "4"){
		acttb1 = false;
		acttb2 = false;
		acttb3 = false;
		acttb4 = true;
		acttb5 = false;
		
		ActiveTabLeft('LeftTab4');
		ActiveTabMid('MidTab4');
		ActiveTabRight('RightTab4');
		ActiveTabText('Tab4Text');
		showdiv('TabBody4');
		
		DeactiveTabLeft('LeftTab2');
		DeactiveTabMid('MidTab2');
		DeactiveTabRight('RightTab2');
		DeactiveTabText('Tab2Text');
		hidediv('TabBody2');
		
		DeactiveTabLeft('LeftTab3');
		DeactiveTabMid('MidTab3');
		DeactiveTabRight('RightTab3');
		DeactiveTabText('Tab3Text');
		hidediv('TabBody3');
		
		DeactiveTabLeft('LeftTab1');
		DeactiveTabMid('MidTab1');
		DeactiveTabRight('RightTab1');
		DeactiveTabText('Tab1Text');
		hidediv('TabBody1');
		
		//DeactiveTabLeft('LeftTab5');
		//DeactiveTabMid('MidTab5');
		//DeactiveTabRight('RightTab5');
		//DeactiveTabText('Tab5Text');
		//hidediv('TabBody5');
	
	}
	if (num == "5"){
		acttb1 = false;
		acttb2 = false;
		acttb3 = false;
		acttb4 = false;
		acttb5 = true;
		
		ActiveTabLeft('LeftTab5');
		ActiveTabMid('MidTab5');
		ActiveTabRight('RightTab5');
		ActiveTabText('Tab5Text');
		showdiv('TabBody5');
		
		DeactiveTabLeft('LeftTab2');
		DeactiveTabMid('MidTab2');
		DeactiveTabRight('RightTab2');
		DeactiveTabText('Tab2Text');
		hidediv('TabBody2');
		
		DeactiveTabLeft('LeftTab3');
		DeactiveTabMid('MidTab3');
		DeactiveTabRight('RightTab3');
		DeactiveTabText('Tab3Text');
		hidediv('TabBody3');
		
		DeactiveTabLeft('LeftTab4');
		DeactiveTabMid('MidTab4');
		DeactiveTabRight('RightTab4');
		DeactiveTabText('Tab4Text');
		hidediv('TabBody4');
		
		DeactiveTabLeft('LeftTab1');
		DeactiveTabMid('MidTab1');
		DeactiveTabRight('RightTab1');
		DeactiveTabText('Tab1Text');
		hidediv('TabBody1');
	}
	
}

/////////////////////////////////////////////
function TabOver(num){
	if (num == "1"){
		ActiveTabLeft('LeftTab1');
		ActiveTabMid('MidTab1');
		ActiveTabRight('RightTab1');
		ActiveTabText('Tab1Text');
	}
	if (num == "2"){
		ActiveTabLeft('LeftTab2');
		ActiveTabMid('MidTab2');
		ActiveTabRight('RightTab2');
		ActiveTabText('Tab2Text');
	}
	if (num == "3"){
		ActiveTabLeft('LeftTab3');
		ActiveTabMid('MidTab3');
		ActiveTabRight('RightTab3');
		ActiveTabText('Tab3Text');
	}
	if (num == "4"){
		ActiveTabLeft('LeftTab4');
		ActiveTabMid('MidTab4');
		ActiveTabRight('RightTab4');
		ActiveTabText('Tab4Text');
	}
	if (num == "5"){
		//ActiveTabLeft('LeftTab5');
		//ActiveTabMid('MidTab5');
		//ActiveTabRight('RightTab5');
		//ActiveTabText('Tab5Text');
	}
}


function TabOut(num){
	if (num == "1" && acttb1 == false){
		DeactiveTabLeft('LeftTab1');
		DeactiveTabMid('MidTab1');
		DeactiveTabRight('RightTab1');
		DeactiveTabText('Tab1Text');
	}
	if (num == "2" && acttb2 == false){
		DeactiveTabLeft('LeftTab2');
		DeactiveTabMid('MidTab2');
		DeactiveTabRight('RightTab2');
		DeactiveTabText('Tab2Text');
	}
	if (num == "3" && acttb3 == false){
		DeactiveTabLeft('LeftTab3');
		DeactiveTabMid('MidTab3');
		DeactiveTabRight('RightTab3');
		DeactiveTabText('Tab3Text');
	}
	if (num == "4" && acttb4 == false){
		DeactiveTabLeft('LeftTab4');
		DeactiveTabMid('MidTab4');
		DeactiveTabRight('RightTab4');
		DeactiveTabText('Tab4Text');
	}
	if (num == "5" && acttb5 == false){
		//DeactiveTabLeft('LeftTab5');
		//DeactiveTabMid('MidTab5');
		//DeactiveTabRight('RightTab5');
		//DeactiveTabText('Tab5Text');
	}
}


