var myFirst = ['nav2', 'nav3', 'nav4', 'nav5','nav6','nav7','nav8','nav9'];
var mySecond = ['106', '190', '287', '381', '493', '561', '640', '709'];

var MySecond = ['n2', 'n3', 'n4', 'n5', 'n6', 'n7', 'n8', 'n9'];


var Browser = {
	Version: function() {
		var version = 999; // we assume a sane browser
		if (navigator.appVersion.indexOf("MSIE") != -1)
		// bah, IE again, lets downgrade version number
		version = parseFloat(navigator.appVersion.split("MSIE")[1]);
		return version;
	}
}

function show(first, second) {
	
var myLeft;
var myDifference;
var myWidth;
	
if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    //IE 6+ in 'standards compliant mode'
    myWidth = document.documentElement.clientWidth;
    
} else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
    //IE 4 compatible
    myWidth = document.body.clientWidth;
} else {
    myWidth = window.innerWidth;
}


if (document.all) { //IS IE 4 or 5 (or 6 beta)
	for ( var i=0, len=myFirst.length; i<len; ++i ){
		if (myFirst[i]==first) {
			if (myWidth <= 980) {myLeft = mySecond[i];}
			else {
				myDifference = myWidth - 980;
				myDifference = Math.round(myDifference/2);
				nettoValue = mySecond[i] * 1;
				myLeft = nettoValue + myDifference;
			
			}
			eval( "document.all." + first + ".style.left = '" + myLeft + "px'");
			eval( "document.all." + first + ".style.visibility = 'visible'");
			if (Browser.Version() < 8) { 
				eval( "document.all." + second + ".style.left = '" + myLeft + "px'");
				eval( "document.all." + second + ".style.visibility = 'visible'");
			}
		}
		else {
			if (Browser.Version() < 8) { 
				eval( "document.all." + MySecond[i] + ".style.visibility = 'hidden'");
			}
			eval( "document.all." + myFirst[i] + ".style.visibility = 'hidden'");
		}

	}

}







if (document.layers) { //IS NETSCAPE 4 or below
document.layers[first].visibility = 'visible';
}



if (document.getElementById && !document.all) {
	
	for ( var i=0, len=myFirst.length; i<len; ++i ){
		if (myFirst[i]==first) {
			if (myWidth <= 980) {myLeft = mySecond[i];}
			else {
				myDifference = myWidth - 980;
				myDifference = Math.round(myDifference/2);
				nettoValue = mySecond[i] * 1;
				myLeft = nettoValue + myDifference;				
			}	
			myLeft = myLeft + 'px';
			maxwell_n1 = document.getElementById(first);
			maxwell_n1.style.visibility = 'visible';
			maxwell_n1.style.left = myLeft;
		}
		else {
			maxwell_n1 = document.getElementById(myFirst[i]);
			maxwell_n1.style.visibility = 'hidden';
		}

	}
	
}

}



function hide(first, second) {

if (document.all) { //IS IE 4 or 5 (or 6 beta)
	if (Browser.Version() < 8) { 
		eval( "document.all." + second + ".style.visibility = 'hidden'");
	}
eval( "document.all." + first + ".style.visibility = 'hidden'");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers[first].visibility = 'hidden';
}
if (document.getElementById && !document.all) {
maxwell_n1 = document.getElementById(first);
maxwell_n1.style.visibility = 'hidden';
}
}



function showSubmenu3() {	
var myLeft;
var myLeft1;
var myDifference;
var myWidth;

if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    //IE 6+ in 'standards compliant mode'
    myWidth = document.documentElement.clientWidth;
    
} else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
    //IE 4 compatible
    myWidth = document.body.clientWidth;
} else {
    myWidth = window.innerWidth;
}


if (document.all) { //IS IE 4 or 5 (or 6 beta)

			if (myWidth <= 980) {myLeft = 190;}
			else {
				myDifference = myWidth - 980;
				myDifference = Math.round(myDifference/2);
				nettoValue = 190 * 1;
				myLeft = nettoValue + myDifference;
			
			}
			myLeft1 = myLeft + 150;
			eval( "document.all.nav3.style.left = '" + myLeft + "px'");
			eval( "document.all.nav3.style.visibility = 'visible'");
			eval( "document.all.nav3a.style.left = '" + myLeft1 + "px'");
			eval( "document.all.nav3a.style.visibility = 'visible'");
			if (Browser.Version() < 8) { 
				eval( "document.all.n3.style.left = '" + myLeft + "px'");
				eval( "document.all.n3.style.visibility = 'visible'");
				eval( "document.all.n3a.style.left = '" + myLeft1 + "px'");
				eval( "document.all.n3a.style.visibility = 'visible'");
			}
			
			if (Browser.Version() < 8) { 
				eval( "document.all.n2.style.visibility = 'hidden'");
				eval( "document.all.n4.style.visibility = 'hidden'");
				eval( "document.all.n5.style.visibility = 'hidden'");
				eval( "document.all.n6.style.visibility = 'hidden'");
				eval( "document.all.n7.style.visibility = 'hidden'");
				eval( "document.all.n8.style.visibility = 'hidden'");
				eval( "document.all.n9.style.visibility = 'hidden'");
			}
			eval( "document.all.nav2.style.visibility = 'hidden'");
			eval( "document.all.nav4.style.visibility = 'hidden'");
			eval( "document.all.nav5.style.visibility = 'hidden'");
			eval( "document.all.nav6.style.visibility = 'hidden'");
			eval( "document.all.nav7.style.visibility = 'hidden'");
			eval( "document.all.nav8.style.visibility = 'hidden'");
			eval( "document.all.nav9.style.visibility = 'hidden'");

}


if (document.getElementById && !document.all) {

			if (myWidth <= 980) {
				myLeft = 190;
				myLeft0 = myLeft + 'px';
			}
			else {
				myDifference = myWidth - 980;
				myDifference = Math.round(myDifference/2);
				nettoValue = 190 * 1;
				myLeft = nettoValue + myDifference;
				myLeft0 = myLeft + 'px';
			}
			myLeft1 = myLeft + 150;
			myLeft1 = myLeft1 + 'px';
			maxwell_n1 = document.getElementById('nav3');
			maxwell_n1.style.visibility = 'visible';
			maxwell_n1.style.left = myLeft0;
			maxwell_n1a = document.getElementById('nav3a');
			maxwell_n1a.style.visibility = 'visible';
			maxwell_n1a.style.left = myLeft1;
	
			maxwell_n2 = document.getElementById('nav2');
			maxwell_n2.style.visibility = 'hidden';
			maxwell_n4 = document.getElementById('nav4');
			maxwell_n4.style.visibility = 'hidden';
			maxwell_n5 = document.getElementById('nav5');
			maxwell_n5.style.visibility = 'hidden';
			maxwell_n6 = document.getElementById('nav6');
			maxwell_n6.style.visibility = 'hidden';
			maxwell_n7 = document.getElementById('nav7');
			maxwell_n7.style.visibility = 'hidden';
			maxwell_n8 = document.getElementById('nav8');
			maxwell_n8.style.visibility = 'hidden';
			maxwell_n9 = document.getElementById('nav9');
			maxwell_n9.style.visibility = 'hidden';
		
}

}


function hideSubmenu3() {

if (document.all) { //IS IE 4 or 5 (or 6 beta)
	if (Browser.Version() < 8) { 
		eval( "document.all.n3a.style.visibility = 'hidden'");
		eval( "document.all.n3.style.visibility = 'hidden'");
		
	}
eval( "document.all.nav3a.style.visibility = 'hidden'");
eval( "document.all.nav3.style.visibility = 'hidden'");
}

if (document.getElementById && !document.all) {
maxwell_n1 = document.getElementById('nav3a');
maxwell_n1.style.visibility = 'hidden';
maxwell_n2 = document.getElementById('nav3');
maxwell_n2.style.visibility = 'hidden';
}
}










////////////

function showSubmenu6() {	
var myLeft;
var myLeft1;
var myDifference;
var myWidth;

if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    //IE 6+ in 'standards compliant mode'
    myWidth = document.documentElement.clientWidth;
    
} else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
    //IE 4 compatible
    myWidth = document.body.clientWidth;
} else {
    myWidth = window.innerWidth;
}


if (document.all) { //IS IE 4 or 5 (or 6 beta)

			if (myWidth <= 980) {myLeft = 493;}
			else {
				myDifference = myWidth - 980;
				myDifference = Math.round(myDifference/2);
				nettoValue = 493 * 1;
				myLeft = nettoValue + myDifference;
			
			}
			myLeft1 = myLeft + 150;
			eval( "document.all.nav6.style.left = '" + myLeft + "px'");
			eval( "document.all.nav6.style.visibility = 'visible'");
			eval( "document.all.nav6a.style.left = '" + myLeft1 + "px'");
			eval( "document.all.nav6a.style.visibility = 'visible'");
			if (Browser.Version() < 8) { 
				eval( "document.all.n6.style.left = '" + myLeft + "px'");
				eval( "document.all.n6.style.visibility = 'visible'");
				eval( "document.all.n6a.style.left = '" + myLeft1 + "px'");
				eval( "document.all.n6a.style.visibility = 'visible'");
			}
			
			if (Browser.Version() < 8) { 
				eval( "document.all.n2.style.visibility = 'hidden'");
				eval( "document.all.n3.style.visibility = 'hidden'");
				eval( "document.all.n4.style.visibility = 'hidden'");
				eval( "document.all.n5.style.visibility = 'hidden'");
				eval( "document.all.n7.style.visibility = 'hidden'");
				eval( "document.all.n8.style.visibility = 'hidden'");
				eval( "document.all.n9.style.visibility = 'hidden'");
			}
			eval( "document.all.nav2.style.visibility = 'hidden'");
			eval( "document.all.nav3.style.visibility = 'hidden'");
			eval( "document.all.nav4.style.visibility = 'hidden'");
			eval( "document.all.nav5.style.visibility = 'hidden'");
			eval( "document.all.nav7.style.visibility = 'hidden'");
			eval( "document.all.nav8.style.visibility = 'hidden'");
			eval( "document.all.nav9.style.visibility = 'hidden'");

}


if (document.getElementById && !document.all) {

			if (myWidth <= 980) {
				myLeft = 493;
				myLeft0 = myLeft + 'px';
			}
			else {
				myDifference = myWidth - 980;
				myDifference = Math.round(myDifference/2);
				nettoValue = 493 * 1;
				myLeft = nettoValue + myDifference;
				myLeft0 = myLeft + 'px';
			}
			myLeft1 = myLeft + 150;
			myLeft1 = myLeft1 + 'px';
			maxwell_n1 = document.getElementById('nav6');
			maxwell_n1.style.visibility = 'visible';
			maxwell_n1.style.left = myLeft0;
			maxwell_n1a = document.getElementById('nav6a');
			maxwell_n1a.style.visibility = 'visible';
			maxwell_n1a.style.left = myLeft1;
	
			maxwell_n2 = document.getElementById('nav2');
			maxwell_n2.style.visibility = 'hidden';
			maxwell_n3 = document.getElementById('nav2');
			maxwell_n3.style.visibility = 'hidden';
			maxwell_n4 = document.getElementById('nav4');
			maxwell_n4.style.visibility = 'hidden';
			maxwell_n5 = document.getElementById('nav5');
			maxwell_n5.style.visibility = 'hidden';
			maxwell_n7 = document.getElementById('nav7');
			maxwell_n7.style.visibility = 'hidden';
			maxwell_n8 = document.getElementById('nav8');
			maxwell_n8.style.visibility = 'hidden';
			maxwell_n9 = document.getElementById('nav9');
			maxwell_n9.style.visibility = 'hidden';
		
}

}


function hideSubmenu6() {

if (document.all) { //IS IE 4 or 5 (or 6 beta)
	if (Browser.Version() < 8) { 
		eval( "document.all.n6a.style.visibility = 'hidden'");
		eval( "document.all.n6.style.visibility = 'hidden'");
		
	}
eval( "document.all.nav6a.style.visibility = 'hidden'");
eval( "document.all.nav6.style.visibility = 'hidden'");
}

if (document.getElementById && !document.all) {
maxwell_n1 = document.getElementById('nav6a');
maxwell_n1.style.visibility = 'hidden';
maxwell_n3 = document.getElementById('nav6');
maxwell_n3.style.visibility = 'hidden';
}
}

function hide3() {
var intValue = 0
if (document.all) { //IS IE 4 or 5 (or 6 beta)
eval( "document.all.n3a.style.visibility = 'hidden'");
eval( "document.all.nav3a.style.visibility = 'hidden'");
}
if (document.getElementById && !document.all) {
maxwell_n3 = document.getElementById('n3a');
maxwell_n3.style.visibility = 'hidden';
maxwell_n4 = document.getElementById('nav3a');
maxwell_n4.style.visibility = 'hidden';
}
}


function hide6() {
var intValue = 0
if (document.all) { //IS IE 4 or 5 (or 6 beta)
eval( "document.all.n6a.style.visibility = 'hidden'");
eval( "document.all.nav6a.style.visibility = 'hidden'");
}
if (document.getElementById && !document.all) {
maxwell_n3 = document.getElementById('n6a');
maxwell_n3.style.visibility = 'hidden';
maxwell_n4 = document.getElementById('nav6a');
maxwell_n4.style.visibility = 'hidden';
}
}

