function obrir_finestra1(pagina)
{
var myLeft = (screen.width-430)/2;
var myTop = (screen.height-330)/2;

var opciones="toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=1, resizable=no, width=430, height=330, top="+myTop+", left="+myLeft+"";
window.open(pagina,"",opciones);
}

function obrir_finestra2(pagina)
{
var myLeft = (screen.width-420)/2;
var myTop = (screen.height-335)/2;

var opciones="toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=1, resizable=no, width=420, height=340, top="+myTop+", left="+myLeft+"";
window.open(pagina,"",opciones);
}

function obrir_finestra3(pagina)
{
var myLeft = (screen.width-420)/2;
var myTop = (screen.height-335)/2;

var opciones="toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=1, resizable=no, width=420, height=340, top="+myTop+", left="+myLeft+"";
window.open(pagina,"",opciones);
}
function obrir_finestra4(pagina)
{
var myLeft = (screen.width-410)/2;
var myTop = (screen.height-200)/2;

var opciones="toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, width=410, height=200, top="+myTop+", left="+myLeft+"";
window.open(pagina,"",opciones);
}

function obrir_finestra5(pagina)
{
var myLeft = (screen.width-800)/2;
var myTop = (screen.height-600)/2;

var opciones="toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=1, resizable=no, width=800, height=600, top="+myTop+", left="+myLeft+"";
window.open(pagina,"",opciones);
}

function comprovar_formulari_contacte(formulari)
	{

	document.getElementById('error0').style.visibility="hidden"; 
	document.getElementById('error1').style.visibility="hidden"; 
	document.getElementById('error2').style.visibility="hidden"; 
	document.getElementById('error3').style.visibility="hidden"; 
	document.getElementById('error4').style.visibility="hidden"; 
	
	
	if (formulari.x_nombre.value=='')
	{
		document.getElementById('error0').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_apellido.value=='')
	{
		document.getElementById('error1').style.visibility="visible"; 
		return false;
	}
							
	if (formulari.x_telefono.value=='')
	{
		document.getElementById('error2').style.visibility="visible"; 
		return false;
	}
	if (formulari.x_mail.value=='')
	{
		document.getElementById('error3').style.visibility="visible"; 
		return false;
	}	

	if (formulari.x_politica[1].checked)
	{
		document.getElementById('error4').style.visibility="visible"; 
		return false;
	}
						

		return true;
}

function comprovar_formulari_quedamos(formulari)
	{

	document.getElementById('error0').style.visibility="hidden"; 
	document.getElementById('error1').style.visibility="hidden"; 
	document.getElementById('error2').style.visibility="hidden"; 
	document.getElementById('error3').style.visibility="hidden"; 

	document.getElementById('error4').style.visibility="hidden"; 
	document.getElementById('error5').style.visibility="hidden"; 
	document.getElementById('error6').style.visibility="hidden"; 	
	
	if (formulari.x_nom_propi.value=='')
	{
		document.getElementById('error0').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_mail_propi.value=='')
	{
		document.getElementById('error1').style.visibility="visible"; 
		return false;
	}
							
	if (formulari.x_nom_receptor.value=='')
	{
		document.getElementById('error2').style.visibility="visible"; 
		return false;
	}
	if (formulari.x_mail_receptor.value=='')
	{
		document.getElementById('error3').style.visibility="visible"; 
		return false;
	}	

	if (formulari.x_fecha.value=='')
	{
		document.getElementById('error4').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_hora.value=='')
	{
		document.getElementById('error5').style.visibility="visible"; 
		return false;
	}
		
	if (formulari.x_politica[1].checked)
	{
		document.getElementById('error6').style.visibility="visible"; 
		return false;
	}
						

		return true;
}

function comprovar_formulari_recomienda(formulari)
	{

	document.getElementById('error0').style.visibility="hidden"; 
	document.getElementById('error1').style.visibility="hidden"; 
	document.getElementById('error2').style.visibility="hidden"; 
	document.getElementById('error3').style.visibility="hidden"; 

	document.getElementById('error4').style.visibility="hidden"; 

	
	
	if (formulari.x_nombre_propio.value=='')
	{
		document.getElementById('error0').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_mail_propio.value=='')
	{
		document.getElementById('error1').style.visibility="visible"; 
		return false;
	}
							
	if (formulari.x_nombre_receptor.value=='')
	{
		document.getElementById('error2').style.visibility="visible"; 
		return false;
	}
	if (formulari.x_mail_receptor.value=='')
	{
		document.getElementById('error3').style.visibility="visible"; 
		return false;
	}	

		
	if (formulari.x_politica[1].checked)
	{
		document.getElementById('error4').style.visibility="visible"; 
		return false;
	}
						

		return true;
}

function comprovar_formulari_reservas(formulari)
	{

	document.getElementById('error0').style.visibility="hidden"; 
	document.getElementById('error1').style.visibility="hidden"; 
	document.getElementById('error2').style.visibility="hidden"; 
	document.getElementById('error3').style.visibility="hidden"; 
	document.getElementById('error4').style.visibility="hidden"; 
	document.getElementById('error5').style.visibility="hidden"; 
	document.getElementById('error6').style.visibility="hidden"; 
	document.getElementById('error7').style.visibility="hidden"; 
	
	
	if (formulari.x_nombre.value=='')
	{
		document.getElementById('error0').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_apellido.value=='')
	{
		document.getElementById('error1').style.visibility="visible"; 
		return false;
	}
							
	if (formulari.x_telefono.value=='')
	{
		document.getElementById('error2').style.visibility="visible"; 
		return false;
	}
	if (formulari.x_mail.value=='')
	{
		document.getElementById('error3').style.visibility="visible"; 
		return false;
	}	
	if (formulari.x_fecha.value=='')
	{
		document.getElementById('error4').style.visibility="visible"; 
		return false;
	}	
	if (formulari.x_hora.value=='')
	{
		document.getElementById('error5').style.visibility="visible"; 
		return false;
	}		

	if (formulari.x_comensales.value=='')
	{
		document.getElementById('error6').style.visibility="visible"; 
		return false;
	}	
	

			
	if (formulari.x_politica[1].checked)
	{
		document.getElementById('error7').style.visibility="visible"; 
		return false;
	}
						

		return true;
}

function comprovar_formulari_trabaja(formulari)
	{

	document.getElementById('error0').style.visibility="hidden"; 
	document.getElementById('error1').style.visibility="hidden"; 
	document.getElementById('error2').style.visibility="hidden"; 
	document.getElementById('error3').style.visibility="hidden"; 

	document.getElementById('error4').style.visibility="hidden"; 
	document.getElementById('error5').style.visibility="hidden"; 
	document.getElementById('error6').style.visibility="hidden"; 
	
	if (formulari.x_nombre.value=='')
	{
		document.getElementById('error0').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_apellido.value=='')
	{
		document.getElementById('error1').style.visibility="visible"; 
		return false;
	}
							
	if (formulari.x_edad.value=='')
	{
		document.getElementById('error2').style.visibility="visible"; 
		return false;
	}
	if (formulari.x_telefono.value=='')
	{
		document.getElementById('error3').style.visibility="visible"; 
		return false;
	}	

	if (formulari.x_mail.value=='')
	{
		document.getElementById('error4').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_cv.value=='')
	{
		document.getElementById('error5').style.visibility="visible"; 
		return false;
	}
		
	if (formulari.x_politica[1].checked)
	{
		document.getElementById('error6').style.visibility="visible"; 
		return false;
	}
						

		return true;
}

function comprovar_formulari_opinion(formulari)
	{

	document.getElementById('error0').style.visibility="hidden"; 
	document.getElementById('error1').style.visibility="hidden"; 
	document.getElementById('error2').style.visibility="hidden"; 
	document.getElementById('error3').style.visibility="hidden"; 

	document.getElementById('error4').style.visibility="hidden"; 
	document.getElementById('error5').style.visibility="hidden"; 
	
	
	if (formulari.x_nombre.value=='')
	{
		document.getElementById('error0').style.visibility="visible"; 
		return false;
	}

	if (formulari.x_apellido.value=='')
	{
		document.getElementById('error1').style.visibility="visible"; 
		return false;
	}
							
	if (formulari.x_telefono.value=='')
	{
		document.getElementById('error2').style.visibility="visible"; 
		return false;
	}
	if (formulari.x_mail.value=='')
	{
		document.getElementById('error3').style.visibility="visible"; 
		return false;
	}	

	if (formulari.x_opinion.value=='')
	{
		document.getElementById('error4').style.visibility="visible"; 
		return false;
	}

		
	if (formulari.x_politica[1].checked)
	{
		document.getElementById('error5').style.visibility="visible"; 
		return false;
	}
						

		return true;
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
