function renderInfoFlash(flashDoc, width, height, bgcolor){
	document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="https://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0"' +
		'	width="' + width + '" height="' + height + '" id="eXpressInfo" align="middle">' +
		'	<param name="allowScriptAccess" value="sameDomain" />' +
		'	<param name="movie" value="' + flashDoc + '" />' +
		'	<param name="quality" value="high" />' +
		'	<param name="bgcolor" value="' + bgcolor + '" />' +
		'	<embed src="' + flashDoc + '" quality="high" bgcolor="' + bgcolor + '" width="' + width + '" height="' + height + '"' +
		'		name="eXpressInfo" align="middle" allowscriptaccess="sameDomain" type="application/x-shockwave-flash"' +
		'		pluginspage="https://www.macromedia.com/go/getflashplayer" />' +
		'</object>');
}
//Some Browser Detection
function BrowserInfo() 
{ 
	var agent = navigator.userAgent.toLowerCase(); 
	this.major = parseInt(navigator.appVersion); 
	this.minor = parseFloat(navigator.appVersion); 
	this.op = (agent.indexOf("opera")!= -1); 
} 
var is = new BrowserInfo(); 
//Determine the Available width on the page 
var fwidth; 

if(document.all) 
{ 
	//For old IE browsers 
	document.documentElement.clientWidth; 
	
} 
else if(document.getElementById &&!document.all) 
{ 
	//For DOM1 browsers 
	fwidth = innerWidth; 
} 
else if(document.getElementById) 
{ 
	fwidth = innerwidth; 
} 
else if (is.op) 
{ 
	//For Opera 
	fwidth = innerwidth; 
} 
else if (document.layers) 
{ 
	//For old Netscape 
	fwidth = window.innerwidth; 
} 
var layerLeft; 

/*Calculate the Left position of the Layer 
the figure being subtracted is half the width of 
the layer that you are trying to position. */ 
layerLeft = fwidth/2;
if(fwidth < 777){
	layerLeft = 402
}
function tbrows(){
	this.pre = "document.all."; 
	this.post = ".style"; 
	if (document.all){
		this.pre = 'document.all.'; 
		this.post = '.style';
	} else if (	document.getElementById){
		this.pre = 'document.getElementById("'; 
		this.post = '").style';
	} else if (document.layers){
		this.pre = 'document.'; 
		this.post = '';
	}
}
function showLayer(theMenu,zPos)
{
	var brs = new tbrows();
	var myLayer = eval(brs.pre + theMenu + brs.post);
	//var myLayer = document.getElementById(theMenu).style;
	myLayer.visibility = 'visible';
	if(!document.layers){
		if( zPos == 1 ) {
			myLayer.position = 'relative';
		}else{
			myLayer.position = 'absolute';
		}		
	}
	myLayer.visibility = 'visible';
	brs = null;
}
function hideLayer(theMenu,zPos){
	var brs = new tbrows();
	var myLayer = eval(brs.pre + theMenu + brs.post);
	myLayer.visibility = 'hidden';
	if(!document.layers){
		if( zPos == 1 ) {
			myLayer.position = 'absolute';
		}else{
			myLayer.position = 'relative';
		}		
	}	
	brs = null;
}
function showOptions(){

}
function hideNShow(theMenus,zPoss,fisrsAct){
	var brs = new tbrows();
	//alert(brs.pre);
	var myLayer = eval(brs.pre + theMenus + brs.post);
	//alert(myLayer.visible);
	if (myLayer.visibility == '' || myLayer.visibility == null){
		//alert(fisrsAct);
		if ( fisrsAct == 1 ) {
			hideLayer(theMenus,zPoss);
		}else{
			showLayer(theMenus,zPoss);
		}	
	}else{
		if (myLayer.visibility == 'visible'){
			hideLayer(theMenus,zPoss);
		}else{
			showLayer(theMenus,zPoss);
		}		
	}

	brs = null;
}
function hideNShow2(theMenus,zPoss,fisrsAct){
	var brs = new tbrows();
	//alert(brs.pre);
	var myLayer = eval(brs.pre + theMenus + brs.post);
	//alert(myLayer.visible);
	if (myLayer.visibility == '' || myLayer.visibility == null){
		//alert(fisrsAct);
		if ( fisrsAct == 1 ) {
			hideLayer(theMenus,1);
		}else{
			showLayer(theMenus,zPoss);
		}	
	}else{
		if (myLayer.visibility == 'visible'){
			hideLayer(theMenus,1);
		}else{
			showLayer(theMenus,zPoss);
		}		
	}

	brs = null;
}
function openRelLayer(LayerID,zViz,tleft,ttop,zPos){
	var zInd = 1;
	if(LayerID == "PopUp"){
		zInd = 0;
	}
	if (document.getElementById || document.all){
		if(zViz==1){
			zVizibility='visible';
		} else{
			zVizibility='hidden';
		} 
		if( zPos == 1 ) {
			zPozition='relative';
		}else{
			zPozition='absolute';
		}
		document.write("<div id='" + LayerID + "' style='left: " + tleft + "px; top: " + ttop + "px;  visibility: " + zVizibility + "; position: " + zPozition + "; z-index:" + zInd + ";'>");
	} else if (document.layers){
		document.write("<layer id='" + LayerID + "' left='0' top='0' visibility='" + zVizibility + "' z-index='" + zInd + "'>");
	}
}
function closeRelLayer(){if (document.getElementById || document.all){document.write("</div>");} else if (document.layers){document.write("</layer>");}}
function moveAll(){
	//For old IE browsers 
	if(document.all) 
	{ 
	fwidth = document.body.clientWidth; 
	} 
	//For DOM1 browsers 
	else if(document.getElementById &&!document.all) 
	{ 
	fwidth = innerWidth; 
	} 
	else if(document.getElementById) 
	{ 
	fwidth = innerwidth; 
	} 
	//For Opera 
	else if (is.op) 
	{ 
	fwidth = innerwidth; 
	} 
	//For old Netscape 
	else if (document.layers) 
	{ 
	fwidth = window.innerwidth; 
	} 
	/*Calculate the Left position of the Layer 
	the figure being subtracted is half the width of 
	the layer that you are trying to position. */ 
	layerLeft = fwidth/2;
	if(fwidth < 777){
		layerLeft = 402
	}
	var myLayer = eval(pre + 'menu1' + post); myLayer.left = layerLeft-380;
	var myLayer = eval(pre + 'menu2' + post); myLayer.left = layerLeft-400;
	var myLayer = eval(pre + 'menu3' + post); myLayer.left = layerLeft-190;
	if(isDefault){
		var myLayer = eval(pre + 'PopUp' + post); myLayer.left = layerLeft-386;
		var myLayer = eval(pre + 'vedload' + post); myLayer.left = layerLeft-365;
	}
}
function hideAll(){
	//hideLayer('menu1');
	//hideLayer('menu2');
	//hideLayer('menu3');

}
function addLoadEvent(func) {
  var oldonload = window.onload;
  if (typeof window.onload != 'function') {
    window.onload = func;
  } else {
    window.onload = function() {
      if (oldonload) {
        oldonload();
      }
      func();
    }
  }
}
