function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function loadFlash()
{
	strDiv = document.getElementById('flashLayer');
	
	strHTML = '<div style="position:absolute;"><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="285" height="407" align="left">';
	strHTML += '<param name="movie" value="http://www.merlin-cyprus.net/merlin_intro2.swf" />';
	strHTML += '<param name="quality" value="high" />';
	strHTML += '<param name="wmode" value="transparent" />';
	strHTML += '<embed src="http://www.merlin-cyprus.net/merlin_intro2.swf" width="285" height="407" align="left" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="transparent"></embed></object></div>';
	strDiv.innerHTML = strHTML;

}
function startScroll()
{
	 iId = setTimeout('checkScroll()',55);
}
var iHide = 0;
function montre(id) 
{
	var d = document.getElementById(id);
	if (d) 
	{
		for (var i = 1; i<=5; i++) 
		{
			if (document.getElementById('smenu'+i)) 
			{
				document.getElementById('smenu'+i).style.display='none';
			}
		}
		d.style.display='block';
		if (iHide == 1)
		{
			clearTimeout(iOut);
			iHide = 0;
		}
	}
	else
	{
		if (iHide == 0)
		{
			iHide = 1;
			iOut = setTimeout('hideAll()',250);
		}
		else
		{
			hideAll();
		}
	}
}
function hideAll()
{
	for (var i = 1; i<=5; i++) 
	{
		if (document.getElementById('smenu'+i)) 
		{
			document.getElementById('smenu'+i).style.display='none';
		}
	}
}
function checkScroll()
{
	if (parseInt(navigator.appVersion)>3) 
	{
	 	if (navigator.appName=="Netscape") 
		{
			winH = window.innerHeight-16;
		}
		if (navigator.appName.indexOf("Microsoft")!=-1) 
		{
			winH = document.body.offsetHeight-20;
		}
	}
	iHeight = winH - 76;
	iLHeight = winH -506;
	iLHeight = iLHeight - 111;
	iLHeight = iLHeight / 2;
	iHeight = iHeight - 113;
	iCheck = 429+113+76;
	if (winH <= iCheck)
	{
		iHeight = 429;
		iLHeight = 1;
	}
	strDiv = document.getElementById("cont");
	strDiv.style.height = iHeight;
	strDiv = document.getElementById("contfoot");
	strDiv.style.top = iHeight+76;
	strDiv = document.getElementById("finalimage");
	strDiv.style.top = iHeight+76;
	strDiv = document.getElementById("lcenter1");
	strDiv.style.height = iLHeight;
	strDiv = document.getElementById("lcenter2");
	strDiv.style.height = iLHeight;	
	strDiv = document.getElementById("rcenter1");
	strDiv.style.height = iLHeight;
	strDiv = document.getElementById("rcenter2");
	strDiv.style.height = iLHeight;	
	strDiv = document.getElementById("center1");
	strDiv.style.height = iLHeight;
	strDiv = document.getElementById("center2");
	strDiv.style.height = iLHeight;	
	iId = setTimeout('checkScroll()',55);
}
function clWin()
{
	montre('');
}
