// set browser function now in General.JS

/* START - Menu Scripts */

var width = 140;
var height = 18;
var page;
var mC = arrMenus.length;
var mC2 = arrMenus2.length;

var w = 0;
var w2 = 0;
var menuGap = 2;
var left = 0;

// allows for scrollbars
var offsetRight = 0;
var offTop = 0;
var offLeft = 0;
var m = null;
var m2 = null;
var mTimer = null;
var tTimer = null;

if(is.ie4) {
	var pre = 'document.all';
	var suf = '.style';
}
if(is.ns4 || is.ns6) {
	var pre = 'document'
	var suf = '';
}

for(var i = 0; i < mC; i ++) {
	w += arrMenus[i].width + menuGap;
}
w -= menuGap;


for(var i = 0; i < mC2; i ++) {
	w2 += arrMenus2[i].width + menuGap;
}
w2 -= menuGap;


function fnSetDim(o) {
	offTop = 0;
	offLeft = 0;
	do {
		offTop += o.offsetTop;
		offLeft += o.offsetLeft;
		o = o.offsetParent;
	} while (o.offsetParent.tagName.toLowerCase() != 'body');
}

function fnLoadResizeLoop() {
      if(is.ie4) {
		fnSetDim(document.all.posMenu1);
		offTop += 4;
		offLeft = ((document.body.clientWidth - w) / 2) + offsetRight;
	}
	if(is.ns4) {
		offsetRight = -8;
		offLeft = ((innerWidth - w) / 2) + offsetRight;
		offTop = 86;
	}
	if(is.ns6) {
		fnSetDim(document.getElementById('posMenu1'));
		offTop += 4;
		offLeft -= 4;
	}
  	
	fnLoopMenuPlace();
}

function fnLoadResizeLoop2() {

	if(is.ie4) {
		fnSetDim(document.all.posMenu);
		offTop += 5;
		offLeft = ((document.body.clientWidth - w2) / 2) + offsetRight;
	}
	if(is.ns4) {
		offsetRight = -8;
		offLeft = ((innerWidth - w2) / 2) + offsetRight;
		offTop = 86;
	}
	if(is.ns6) {
		fnSetDim(document.getElementById('posMenu'));
		offTop += 5;
		offLeft -= 2;
	}

	fnLoopMenuPlace2();
}

window.onresize = function fnReset() {
fnLoadResizeLoop2();	
fnLoadResizeLoop();
	
}

function fnWriteMenuInPage() {
	fnWriteCSS();
	//was written twice for some reason?
	//fnWriteCSS();
	fnLoopMenuNav();
}

function fnWriteCSS() {
	document.writeln('<STYLE>');
	document.writeln('.divCatch, .menuLink { color: black; font-family: Arial, Helvetica; font-size: 11px; font-weight: normal; text-decoration: none; }');
	document.writeln('.divCatch { cursor: hand; }');
	document.writeln('.menuOff, .menuOn { border: 1px solid black; }');
	document.writeln('.menuOff { background-color: #CCCCCC; }');
	document.writeln('.menuOn { background-color: #EEEEEE; }');
	document.writeln('</STYLE>');
}


function fnLoopMenuNav() {
	// write the menus
	var s = '';
	for(var i = 0; i < mC; i ++) {
		s += fnWriteMenu(i, page);
	}
	document.write(s);
	document.close();
	fnLoadResizeLoop();
	
	var s2 = '';
	for(var i = 0; i < mC2; i ++) {
		s2 += fnWriteMenu2(i, page);
	}
	document.write(s2);
	document.close();
	fnLoadResizeLoop2();	
}

function fnLoopMenuPlace() {
	// place the menu central to the page
	left = 3;
	for(var i = 0; i < mC; i ++) {
		fnPlaceMenu(i);
		left += arrMenus[i].width + menuGap;
	}
}

function fnLoopMenuPlace2() {
	// place the menu central to the page
	left = 1;
	for(var i = 0; i < mC2; i ++) {
		
		fnPlaceMenu2(i);
		left += arrMenus2[i].width + menuGap;
	}
}

function fnPlaceMenu(j) {
	var l = arrMenus[j].items.length;
	var thisLeft = offLeft + left - j;
	var thisTop = offTop + -5;
	var o;

	for(var i = l - 1; i > -1; i --) {
		o = fnGetObj('lyr_' + j + '_' + i);
		o.visibility = 'visible';
		o.top = thisTop;
		o.left = thisLeft;

		o = fnGetObj('lyr_' + j + '_' + i + '_catch')
		o.visibility = 'visible';
		o.top = thisTop;
		o.left = thisLeft;
	}

	o = fnGetObj('lyr_' + j);
	o.visibility = 'visible';
	o.top = thisTop;
	o.left = thisLeft;

	o = fnGetObj('lyr_' + j + '_catch');
	o.visibility = 'visible';
	o.top = thisTop;
	o.left = thisLeft;

}

function fnPlaceMenu2(j) {
	var l = arrMenus2[j].items.length;
	var thisLeft = offLeft + left - j;
	var thisTop = offTop + -5;
	var o;
	for(var i = l - 1; i > -1; i --) {
		o = fnGetObj('lyr1_' + j + '_' + i);
		o.visibility = 'visible';
		o.top = thisTop;
		o.left = thisLeft;

		o = fnGetObj('lyr1_' + j + '_' + i + '_catch');
		o.visibility = 'visible';
		o.top = thisTop;
		o.left = thisLeft;
	}
	o = fnGetObj('lyr1_' + j);
	o.visibility = 'visible';
	o.top = thisTop;
	o.left = thisLeft;
	
	o = fnGetObj('lyr1_' + j + '_catch');
	o.visibility = 'visible';
	o.top = thisTop;
	o.left = thisLeft;

}

function fnDivChange(d, state) {
	var oL = eval(pre + "['lyr_" + d + "']");
	if(is.ie4)
		var oI = document.all['img_' + d]
	if(is.ns4)
		var oI = eval(pre + "['lyr_" + d + "'].document.images[0]")
	if(is.ns6) {
		var oL = document.getElementById('lyr_' + d)
		var oI = document.getElementById('img_' + d)
	}
	if(is.ie4 || is.ns6) {
		if(state == 'on') {
			oL.className = 'menuOn';
		} else {
			oL.className = 'menuOff';
		}
	}
}

function fnWriteMenu(j, page) {
	var l = arrMenus[j].items.length;
	var thisLeft = 0//offLeft + left - j;
	var thisTop = 0//offTop + 4;
	var sL = '';
	var lN = 'DIV';
	if(is.ns4)
		lN = 'LAYER';
	var sClass = '';

	if(String(arrMenus[j].link).toLowerCase().indexOf(page) != -1) {
		//SET TO 'menuOn' if you want HOME already highlighted
		sClass = 'menuOff';
	} else {
		sClass = 'menuOff';
	}

	if(is.ns4)
		var minim = 4;
	else
		var minim = 0;

	//alert(j + ' - ' + arrMenus[j].string)

	for(var i = l - 1; i > -1; i --) {
		if(is.ns4)
			sL += '<' + lN + ' class="menuOff" id="lyr_' + j + '_' + i + '" bgcolor="#CCCCCC" style="visibility: hidden; position: absolute; left: ' + thisLeft + '; top: ' + thisTop + '; width: ' + arrMenus[j].width + '; height: ' + height + '; z-index: 10; padding: 0;"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + (arrMenus[j].width - minim) + '><TR><TD width=10><A class="menuLink" href="' + arrMenus[j].items[i].link + '" height=' + (height - minim) + '><IMG id="img_' + j + '_' + i + '" src="/assets/imgs/spacer.gif" border=0 height=' + (height - minim) + ' width=8 align=absmiddle></A></TD><TD class=menuLink width=' + (arrMenus[j].width - 16) + ' valign=middle>' + arrMenus[j].items[i].string + '</TD></TR></TABLE></' + lN + '>';
		else
			sL += '<' + lN + ' class="menuOff" id="lyr_' + j + '_' + i + '" style="visibility: hidden; position: absolute; left: ' + thisLeft + '; top: ' + thisTop + '; width: ' + arrMenus[j].width + '; height: ' + height + '; z-index: 10;"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + arrMenus[j].width + '><TR><TD colspan="2" align="center" class=menuLink width=' + (arrMenus[j].width - 0) + '>' + arrMenus[j].items[i].string + '</TD></TR></TABLE></' + lN + '>';
			sL += '<' + lN + ' class=divCatch id="lyr_' + j + '_' + i + '_catch" style="z-index: 10; position: absolute; left: ' + thisLeft + '; top: ' + thisTop + '; width: ' + arrMenus[j].width + '; height: ' + height + ';"><A class="menuLink" href="' + arrMenus[j].items[i].link + '" onmouseover="clearTimeout(tTimer); fnDivChange(\'' + j + '_' + i + '\', \'on\');" onmouseout="tTimer = setTimeout(&quot;fnClearMenu(' + j + ')&quot;, 1000); fnDivChange(\'' + j + '_' + i + '\', \'off\');"><IMG src="/assets/imgs/spacer.gif" width="' + arrMenus[j].width + '" height="' + height + '" border="0"></A></' + lN + '>';
	}

			
	// HACK: in netscape the first layer seems not to work. by adding on this layer, the problem is removed
	sL += '<' + lN + ' id="l_lyr_' + j + '" style="visibility: hidden; z-index: 10; position: absolute; left: 0; top: 0; width: ' + arrMenus[j].width + '; height: ' + height + ';"></' + lN + '>\n\n';

	if(sClass == 'menuOn')
		sL += '<' + lN + ' class="' + sClass + '" id="lyr_' + j + '" bgcolor="#7F7F7F" style="position: absolute; top: 0; left: 0; width: ' + arrMenus[j].width + '; height: ' + height + '; visibility: hidden; z-index: 11; padding: 0"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + (arrMenus[j].width - minim) + '><TR><TD width=10><IMG id="img_' + j + '" src="/assets/imgs/spacer.gif" border=0 width=10 height=' + (height - minim) + '></TD><TD class="menuLink" width=' + (arrMenus[j].width - (10 + minim)) + '>' + arrMenus[j].string + '</TD></TR></TABLE></' + lN + '>';
	else
		sL += '<' + lN + ' class="' + sClass + '" id="lyr_' + j + '" bgcolor="#CCCCCC" style="position: absolute; top: 0; left: 0; width: ' + arrMenus[j].width + '; height: ' + height + '; visibility: hidden; z-index: 11; padding: 0"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + (arrMenus[j].width - minim) + '><TR><TD colspan="2" height="18" align="center" class="menuLink" width=' + (arrMenus[j].width - (0 + minim)) + '>' + arrMenus[j].string + '</TD></TR></TABLE></' + lN + '>';

	if(l > 0) {
		if(sClass == 'menuOn')
			sL += '<' + lN + ' id="lyr_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus[j].width + '; height: ' + (height) + '; z-index: 12;"><A class="menuLink" href="javascript:void(0)"  onmouseover="fnDivChange(' + j + ', \'on\');fnDropMenu(' + j + ');" onclick="fnDropMenu(' + j + ');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus[j].width + '" height="' + (height -minim) + '" border=0></A></' + lN + '>';
		else
			sL += '<' + lN + ' id="lyr_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus[j].width + '; height: ' + (height) + '; z-index: 12;"><A class="menuLink" href="javascript:void(0)"  onmouseover="fnDivChange(' + j + ', \'on\');fnDropMenu(' + j + ');" onclick="fnDropMenu(' + j + ');" onmouseout="fnDivChange(' + j + ', \'off\');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus[j].width + '" height="' + (height - minim) + '" border=0></A></' + lN + '>';
	} else {
		if(sClass == 'menuOn')
			sL += '<' + lN + ' id="lyr_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus[j].width + '; height: ' + (height) + '; z-index: 12;"><A class="menuLink" href="' + arrMenus[j].link + '"  onmouseover="fnDivChange(' + j + ', \'on\');fnDropMenu(' + j + ');" onclick="fnDropMenu(' + j + ');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus[j].width + '" height="' + (height - minim) + '" border=0></A></' + lN + '>';
		else
			sL += '<' + lN + ' id="lyr_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus[j].width + '; height: ' + (height) + '; z-index: 12;"><A class="menuLink" href="' + arrMenus[j].link + '"  onmouseover="fnDivChange(' + j + ', \'on\');fnDropMenu(' + j + ');" onclick="fnDropMenu(' + j + ');" onmouseout="fnDivChange(' + j + ', \'off\');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus[j].width + '" height="' + (height - minim) + '" border=0></A></' + lN + '>';
	}

	return sL;
}

function fnClearDrop(j) {
	
}

function fnHandleLink(u) {
	if(u != 'null')
		document.location.href = u;
}

function fnClearMenu(j) {
	if(j == null)
		return;
	arrMenus[j].out = null;
	clearTimeout(mTimer)
	var l = arrMenus[j].items.length;
	var o
	o = fnGetObj('lyr_' + j)
	var s1 = parseInt(o.top);
	for(var i = 0; i < l; i ++) {
		o = fnGetObj('lyr_' + j + '_' + i)
		o.top = s1;
		o = fnGetObj('lyr_' + j + '_' + i + '_catch')
		o.top = s1;
	}
}

function fnDropMenu(j) {
	if(arrMenus[j].out == j) {
		fnClearMenu(j)
		return;
	}
	arrMenus[j].out = j;
	clearTimeout(tTimer);
	fnClearMenu(m);
	fnClearMenu2(m2);
	m = j;
	var l = arrMenus[j].items.length;
	var o = 0;
	var obj = fnGetObj('lyr_' + j)
	var s = parseInt(obj.top) - 1;
	var f = s + height;
	if(is.ns6)
		f -= 2;
	if(is.ns4)
		f += 4;
	else {
		if(!is.mac)
			f += 2
	}
	fnMoveLyr(j, o, s, f, l - 1);
}

function fnMoveLyr(p, o, s, f, oC) {
	if(oC == -1 || o > oC) {
		return;
	}
	clearTimeout(tTimer)
	var obj = fnGetObj('lyr_' + p + '_' + o)
	var objC = fnGetObj('lyr_' + p + '_' + o + '_catch')
	if(s >= f) {
		clearTimeout(mTimer);
		if(o <= oC) {
			if(is.ns6)
				obj.top = f + 2;
			else
				obj.top = f;
			o++;
			if(o > oC)
				return
			var objT = fnGetObj('lyr_' + p + '_' + (o - 1))
			var t = objT.top;
			var obj = fnGetObj('lyr_' + p + '_' + o)
			obj.top = t;
			objC.top = t;
			var s = parseInt(obj.top) - 1;
			if(is.ns4)
				fnMoveLyr(p, o, s, s + height + 4, oC);
			else
				fnMoveLyr(p, o, s, s + height, oC);
		}
	} else {
		if(is.ns6)
			s += height;
		else
			s += 2;
		obj.top = s;
		objC.top = s;
		mTimer = setTimeout("fnMoveLyr(" + p + ", '" + o + "', " + s + ", " + f + ", " + oC + ")", 1);
	}
}






function fnClearMenu2(j) {
	if(j == null)
		return;
	arrMenus2[j].out = null;
	clearTimeout(mTimer)
	var l = arrMenus2[j].items.length;
	var o
	o = fnGetObj('lyr1_' + j)
	var s1 = parseInt(o.top);
	for(var i = 0; i < l; i ++) {
		o = fnGetObj('lyr1_' + j + '_' + i)
		o.top = s1;
		o = fnGetObj('lyr1_' + j + '_' + i + '_catch')
		o.top = s1;
	}
}



function fnDropMenu2(j) {
	if(arrMenus2[j].out == j) {
		fnClearMenu2(j)
		return;
	}
	arrMenus2[j].out = j;
	clearTimeout(tTimer);
	fnClearMenu(m);
	fnClearMenu2(m2);
	m2 = j;
	var l = arrMenus2[j].items.length;
	var o = 0;
	var obj = fnGetObj('lyr1_' + j)
	var s = parseInt(obj.top) - 1;
	var f = s + height;
	if(is.ns6)
		f -= 2;
	if(is.ns4)
		f += 4;
	else {
		if(!is.mac)
			f += 2
	}
	fnMoveLyr2(j, o, s, f, l - 1);
}


function fnMoveLyr2(p, o, s, f, oC) {
	if(oC == -1 || o > oC) {
		return;
	}
	clearTimeout(tTimer)
	var obj = fnGetObj('lyr1_' + p + '_' + o)
	var objC = fnGetObj('lyr1_' + p + '_' + o + '_catch')
	if(s >= f) {
		clearTimeout(mTimer);
		if(o <= oC) {
			if(is.ns6)
				obj.top = f + 2;
			else
				obj.top = f;
			o++;
			if(o > oC)
				return
			var objT = fnGetObj('lyr1_' + p + '_' + (o - 1))
			var t = objT.top;
			var obj = fnGetObj('lyr1_' + p + '_' + o)
			obj.top = t;
			objC.top = t;
			var s = parseInt(obj.top) - 1;
			if(is.ns4)
				fnMoveLyr2(p, o, s, s + height + 4, oC);
			else
				fnMoveLyr2(p, o, s, s + height, oC);
		}
	} else {
		if(is.ns6)
			s += height;
		else
			s += 2;
		obj.top = s;
		objC.top = s;
		mTimer = setTimeout("fnMoveLyr2(" + p + ", '" + o + "', " + s + ", " + f + ", " + oC + ")", 1);
	}
}



function fnDivChange2(d, state) {
	var oL = eval(pre + "['lyr1_" + d + "']");
	if(is.ie4)
		var oI = document.all['img1_' + d]
	if(is.ns4)
		var oI = eval(pre + "['lyr1_" + d + "'].document.images[0]")
	if(is.ns6) {
		var oL = document.getElementById('lyr1_' + d)
		var oI = document.getElementById('img1_' + d)
	}
	if(is.ie4 || is.ns6) {
		if(state == 'on') {
			oL.className = 'menuOn';
		} else {
			oL.className = 'menuOff';
		}
	}
}


function fnWriteMenu2(j, page) {
	var l = arrMenus2[j].items.length;
	var thisLeft = 0//offLeft + left - j;
	var thisTop = 0//offTop + 4;
	var sL = '';
	var lN = 'DIV';
	if(is.ns4)
		lN = 'LAYER';
	var sClass = '';

	if(String(arrMenus2[j].link).toLowerCase().indexOf(page) != -1) {
		//SET TO 'menuOn' if you want HOME already highlighted
		sClass = 'menuOff';
	} else {
		sClass = 'menuOff';
	}

	if(is.ns4)
		var minim = 4;
	else
		var minim = 0;

	//alert(j + ' - ' + arrMenus2[j].string)

	for(var i = l - 1; i > -1; i --) {
		if(is.ns4)
			sL += '<' + lN + ' class="menuOff" id="lyr1_' + j + '_' + i + '" bgcolor="#CCCCCC" style="visibility: hidden; position: absolute; left: ' + thisLeft + '; top: ' + thisTop + '; width: ' + arrMenus2[j].width + '; height: ' + height + '; z-index: 15; padding: 0;"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + (arrMenus2[j].width - minim) + '><TR><TD width=10><A class="menuLink" href="' + arrMenus2[j].items[i].link + '" height=' + (height - minim) + '><IMG id="img1_' + j + '_' + i + '" src="/assets/imgs/spacer.gif" border=0 height=' + (height - minim) + ' width=8 align=absmiddle></A></TD><TD class=menuLink width=' + (arrMenus2[j].width - 16) + ' valign=middle>' + arrMenus2[j].items[i].string + '</TD></TR></TABLE></' + lN + '>';
		else
			sL += '<' + lN + ' class="menuOff" id="lyr1_' + j + '_' + i + '" style="visibility: hidden; position: absolute; left: ' + thisLeft + '; top: ' + thisTop + '; width: ' + arrMenus2[j].width + '; height: ' + height + '; z-index: 15;"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + arrMenus2[j].width + '><TR><TD colspan="2" align="center" class=menuLink width=' + (arrMenus2[j].width - 0) + '>' + arrMenus2[j].items[i].string + '</TD></TR></TABLE></' + lN + '>';
		sL += '<' + lN + ' class=divCatch id="lyr1_' + j + '_' + i + '_catch" style="z-index: 15; position: absolute; left: ' + thisLeft + '; top: ' + thisTop + '; width: ' + arrMenus2[j].width + '; height: ' + height + ';"><A class="menuLink" href="' + arrMenus2[j].items[i].link + '" onmouseover="clearTimeout(tTimer); fnDivChange2(\'' + j + '_' + i + '\', \'on\');" onmouseout="tTimer = setTimeout(&quot;fnClearMenu2(' + j + ')&quot;, 1000); fnDivChange2(\'' + j + '_' + i + '\', \'off\');"><IMG src="/assets/imgs/spacer.gif" width="' + arrMenus2[j].width + '" height="' + height + '" border="0"></A></' + lN + '>';
	}

			
	// HACK: in netscape the first layer seems not to work. by adding on this layer, the problem is removed
	sL += '<' + lN + ' id="l_lyr1_' + j + '" style="visibility: hidden; z-index: 15; position: absolute; left: 0; top: 0; width: ' + arrMenus2[j].width + '; height: ' + height + ';"></' + lN + '>\n\n';

	if(sClass == 'menuOn')
		sL += '<' + lN + ' class="' + sClass + '" id="lyr1_' + j + '" bgcolor="#7F7F7F" style="position: absolute; top: 0; left: 0; width: ' + arrMenus2[j].width + '; height: ' + height + '; visibility: hidden; z-index: 16; padding: 0"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + (arrMenus2[j].width - minim) + '><TR><TD width=10><IMG id="img1_' + j + '" src="/assets/imgs/spacer.gif" border=0 width=10 height=' + (height - minim) + '></TD><TD class="menuLink" width=' + (arrMenus2[j].width - (10 + minim)) + '>' + arrMenus2[j].string + '</TD></TR></TABLE></' + lN + '>';
	else
		sL += '<' + lN + ' class="' + sClass + '" id="lyr1_' + j + '" bgcolor="#CCCCCC" style="position: absolute; top: 0; left: 0; width: ' + arrMenus2[j].width + '; height: ' + height + '; visibility: hidden; z-index: 17; padding: 0"><TABLE cellpadding=0 cellspacing=0 border=0 width=' + (arrMenus2[j].width - minim) + '><TR><TD colspan="2" height="18" align="center" class="menuLink" width=' + (arrMenus2[j].width - (0 + minim)) + '>' + arrMenus2[j].string + '</TD></TR></TABLE></' + lN + '>';

	if(l > 0) {
		if(sClass == 'menuOn')
			sL += '<' + lN + ' id="lyr1_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus2[j].width + '; height: ' + (height) + '; z-index: 18;"><A class="menuLink" href="javascript:void(0)"  onmouseover="fnDivChange2(' + j + ', \'on\');fnDropMenu2(' + j + ');" onclick="fnDropMenu2(' + j + ');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus2[j].width + '" height="' + (height -minim) + '" border=0></A></' + lN + '>';
		else
			sL += '<' + lN + ' id="lyr1_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus2[j].width + '; height: ' + (height) + '; z-index: 18;"><A class="menuLink" href="javascript:fnRun();"  onmouseover="fnDivChange2(' + j + ', \'on\');fnDropMenu2(' + j + ');" onclick="fnDropMenu2(' + j + ');" onmouseout="fnDivChange2(' + j + ', \'off\');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus2[j].width + '" height="' + (height - minim) + '" border=0></A></' + lN + '>';
	} else {
		if(sClass == 'menuOn')
			sL += '<' + lN + ' id="lyr1_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus2[j].width + '; height: ' + (height) + '; z-index: 18;"><A class="menuLink" href="' + arrMenus2[j].link + '"  onmouseover="fnDivChange2(' + j + ', \'on\');fnDropMenu2(' + j + ');" onclick="fnDropMenu2(' + j + ');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus2[j].width + '" height="' + (height - minim) + '" border=0></A></' + lN + '>';
		else
			sL += '<' + lN + ' id="lyr1_' + j + '_catch" style="border: 1px solid black; position: absolute; left: 0; top: 0; width: ' + arrMenus2[j].width + '; height: ' + (height) + '; z-index: 18;"><A class="menuLink" href="' + arrMenus2[j].link + '"  onmouseover="fnDivChange2(' + j + ', \'on\');fnDropMenu2(' + j + ');" onclick="fnDropMenu2(' + j + ');" onmouseout="fnDivChange2(' + j + ', \'off\');"><IMG id="ed" src="/assets/imgs/spacer.gif" width="' + arrMenus2[j].width + '" height="' + (height - minim) + '" border=0></A></' + lN + '>';
	}

	return sL;
}

function fnRun(){
	document.location.href = "/Telemarketing.asp";
}