//************************************************************** Browser Definition
var isNew = 0;
var isNS4 = 0;
var isIE4 = 0;

var brow = ((navigator.appName) + (parseInt(navigator.appVersion)));
if (parseInt(navigator.appVersion >= 5))
        {isNew = 1;}
else if (brow == 'Netscape4')
        {isNS4 = 1;}
else if (brow == 'Microsoft Internet Explorer4')
        {isIE4 = 1;}
        
if (isNS4||isIE4||isNew)
{
docObj = (isNS4) ? 'document' : 'document.all';
styleObj = (isNS4) ? '' : '.style';
}


//************************************************ Layers

function show_map(item)
{
 dom = eval(docObj + '.' + item + styleObj);
 state = dom.visibility;
 
 		if (state == 'visible' || state == 'show'){
   				dom.visibility = 'hidden';}
 		else{
   				dom.visibility = 'visible';}
} 


function hide_map(item)
{
        if(document.layers)
                document.layers[item].visibility='hide';
        else
                document.all[item].style.visibility='hidden';
} 


//*********************************** Bilder Erholung in Fenster öffnen

function open_win(no){

if (no == 0){
	var win = window.open("piscine.html","","width=330,height=300,top=10,left=350"); win.focus();}
if (no == 1){
	var win = window.open("tennis.html","","width=330,height=300,top=200,left=280"); win.focus();}
if (no == 2){
	var win = window.open("velo.html","","width=330,height=300,top=20,left=20"); win.focus();}
if (no == 3){
	var win = window.open("mer.html","","width=330,height=300,top=250,left=400"); win.focus();}
if (no == 4){
	var win = window.open("vin.html","","width=330,height=300,top=0,left=310"); win.focus();}
if (no == 5){
	var win = window.open("golf.html","","width=330,height=300,top=50,left=430"); win.focus();}
if (no == 6){
	var win = window.open("excurs.html","","width=330,height=300,top=150,left=360"); win.focus();}	

}


//*********************************** Fenster Reservation öffnen

function open_reservation(){
	var win = window.open("http://www.menu-on-line-france.com/hotel-restaurant-saint-alban-pezenas/?lang=fr","","width=860,height=700,top=20,left=20,scrollbars=yes");
	win.focus();
}

//*********************************** Fenster Lageplan öffnen

function open_map(){
	var win = window.open("plan.html","","width=600,height=460,top=20,left=20");
	win.focus();
}

//*********************************** Fenster Preise öffnen

function open_price(){
	var win = window.open("tarif.html","","width=440,height=740,top=5,left=200,scrollbars=yes");
	win.focus();
}

//*********************************** Fenster Programm öffnen

function open_programme(){
	var win = window.open("programme.html","","width=580,height=500,top=5,left=5,scrollbars=yes");
	win.focus();
}

//*********************************** Fenster Tarife öffnen

function open_tarifs(){
	var win = window.open("tarif.html","","width=540,height=560,top=5,left=20");
	win.focus();
}

//*********************************** Fenster Preise Erlebniswochen öffnen

function openPricelist(){
	var win = window.open("tarifs.html","","width=900,height=380,top=20,left=20");
	win.focus();
}
//*********************************** Fenster Annullationsbedingungen öffnen

function open_agb(){
	var win = window.open("agb.html","","width=400,height=300,top=5,left=20");
	win.focus();
}

//*********************************** Fenster Zimmer

function showRooms(no){
	var url = "fotos.php?room=" + no;
	var win = window.open(url,"","width=680,height=640,left=20,top=20,scrollbars=yes,resizable=yes");
	win.focus();
}

//*********************************** Fenster Galerie

function openPic(galerie,lang,id){
	var win = window.open('diashow.php?galerie='+ galerie +'&lang='+ lang +'&id='+ id,'Fotogalerie','width=500,height=500,left=10,top=10');
	win.focus();
}

//************************************* Stimmungsbilder in Fenster öffnen

win = null;

function image_open(newimage,newtitle,newheight,newwidth)
{
   if (win != null && !win.closed){
      win.close(); 
   	}
	
	win_height = newheight + 30;
   	win_width = newwidth + 30;
   	options = 'top=20,left=20,menubar=no,scrollbars=no,toolbar=no,resizable=no,height='+win_height+',width='+win_width;
   	win = window.open('','',options);

      win.document.writeln('<html>');
      win.document.writeln('<head>');
      win.document.writeln('<title>'+newtitle+'</title>');
      win.document.writeln('</head>');
      win.document.writeln('<body bgcolor="#EDF4F7">');     
      win.document.writeln('<div align="center">');
      win.document.writeln('<img src="'+ newimage +'" width="'+ newwidth +'" height="'+ newheight +' border=0 alt="'+ newtitle +'" title="'+ newtitle +'" style="border: 2px solid #000080;">');
      win.document.writeln('</div>');
      win.document.writeln('</body>');
      win.document.writeln('</html>');
	  win.focus();
}

//******************************************************** Fehlermeldungen Kontaktformular

function check_kontakt(){

	if (document.Kontakt.name.value == ""){
		alert('Veuillez entrer votre nom');
		document.Kontakt.name.focus();
		return false;
		}
	if (document.Kontakt.vorname.value == ""){
		alert('Veuillez entrer votre prenom');
		document.Kontakt.vorname.focus();
		return false;
		}
	if (document.Kontakt.telefon.value == ""){
		alert('Veuillez entrer votre telephone');
		document.Kontakt.telefon.focus();
		return false;
		}
	if (document.Kontakt.email.value == ""){
		alert('Veuillez entrer votre email');
		document.Kontakt.email.focus();
		return false;
		}
	if(document.Kontakt.email.value.indexOf('@') == -1 || document.Kontakt.email.value.indexOf('.') == -1){
		alert('Cet email n\'est pas valable');
		document.Kontakt.email.value = "";
		document.Kontakt.email.focus();
		return false;
		}
	}
	
	
//*** GOOGLE ANALYSER ***//
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));

var pageTracker = _gat._getTracker("UA-4137186-1");
pageTracker._initData();
pageTracker._trackPageview();





