<!--
ieHover = function() {
	var ieLIs = document.getElementById('nav').getElementsByTagName('li');
	for (var i=0; i<ieLIs.length; i++) if (ieLIs[i]) {
		ieLIs[i].onmouseover=function() {
			
		var ieUL = this.getElementsByTagName('ul')[0];
		if (ieUL) {
		var ieMat = document.createElement('iframe');
						ieMat.style.width=ieUL.offsetWidth+"px";
						ieMat.style.height=ieUL.offsetHeight+"px";	
						ieUL.insertBefore(ieMat,ieUL.firstChild);
						ieUL.style.zIndex="99";
						}
			
			this.className+=" iehover";
			}
		ieLIs[i].onmouseout=function() {
			this.className=this.className.replace(' iehover', '');
			}
			}
	}
if (window.attachEvent) window.attachEvent('onload', ieHover);


function formValidation(form)
		{
				if(notEmpty(form.Name))
					{
				if(notEmpty(form.Address))
					{
				if(notEmpty(form.Phone))
					{	
				if(notEmpty(form.e_mail))
					{	
				if(notEmpty(form.Yacht_model))
					{	
				if(notEmpty(form.Start_date))
					{	
				if(notEmpty(form.charter_duration))
					{	
									return true;
					}
					}
					}
					}
					}
					}
					}
			return false;
		}

function notEmpty(elem)
{
	var str = elem.value;
	if(str.length == 0)
	{
		alert("please fill empty fields");
		return false;
	}
	else
	{
		return true;
	}
}
function checkemail(source)
{
	var emailFilter=/^.+@.+\..{2,3}$/;
	if (!(emailFilter.test(source.value)))
	{ 
		   alert("please enter valid e-mail!");
		   return false;
   }
   return true;
}
function Check(sender)
{
	if(!formValidation(sender))
	{
		return false;				
	}
	if(!checkemail(sender.e_mail))
	{
		return false;
	}

	return true;
}
//-->

<!--

// toggle visibility 

function toggle( targetId,itemNo ){
	
  if (document.getElementById){
	  
	  for ( var i=1; i<=itemNo; i++){
  		var target = document.getElementById( targetId + i );
		
  			if (target.style.display == "none"){
  				target.style.display ="block";
  			} else {
  				target.style.display = "none";
  			}
	}
  }
}

function toggleLi( targetLiId1,myddID ){
  if (document.getElementById){
	  
  		targetLi1 = document.getElementById( targetLiId1 );
  		targetDD = document.getElementById( "sub" + myddID );
		
  			if (targetLi1.style.display == "none"){
  				targetLi1.style.display = "block";
  			} else {
  				targetLi1.style.display = "none";
  			}
  	}
}

//-->