function buttonOver(button, color) {
	button.style.backgroundColor = color;
}
		
function buttonOut(button){
	button.style.backgroundColor = "";
}

function popupskimap(file){
	var zentrierenX = (screen.width/2)-325; 
	var zentrierenY = (screen.height/2)-285;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(file,"map","width=750, height=600, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}

function popupsubskimap(file,PreMS,PreMOZ){
	
	if (navigator.appName == "Microsoft Internet Explorer"){	
	
		var zentrierenX = (screen.width/2)-325; 
		var zentrierenY = (screen.height/2)-285;
		var pos = "left="+zentrierenX+",top="+zentrierenY; 
		window.open(PreMS + file,"map","width=840, height=600, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
	}
	else {
	
		var zentrierenX = (screen.width/2)-325; 
		var zentrierenY = (screen.height/2)-285;
		var pos = "left="+zentrierenX+",top="+zentrierenY; 
		window.open(PreMOZ + file,"map","width=800, height=6000, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
	}
	
}

function popupbook(file){
	var zentrierenX = (screen.width/2)-350; 
	var zentrierenY = (screen.height/2)-300;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(file,"book","width=750, height=600, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);

}

function popupassistent(file){
	var zentrierenX = (screen.width/2)-271; 
	var zentrierenY = (screen.height/2)-238;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(file,"assistent","width=700, height=500, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}

function popupanfrage(file){
	var zentrierenX = (screen.width/2)-350; 
	var zentrierenY = (screen.height/2)-300;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(file,"anfrage","width=750, height=600, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}

function popupprospekt(){
	var zentrierenX = (screen.width/2)-350; 
	var zentrierenY = (screen.height/2)-300;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open("prospekt.asp","prospekt","width=750, height=600, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}

function popupbrochure(region){
	var zentrierenX = (screen.width/2)-350; 
	var zentrierenY = (screen.height/2)-300;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open("prospekt.asp?region="+region,"prospekt","width=750, height=600, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}

function popupprint(file){
	
	var zentrierenX = (screen.width/2)-350; 
	var zentrierenY = (screen.height/2)-300;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(file,"print","width=660, height=600, resizable=no, scrollbars=yes, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);	
}

function popupsubprint(file,PreMS, PreMOZ){
	
	if (navigator.appName == "Microsoft Internet Explorer"){	
	
		var zentrierenX = (screen.width/2)-350; 
		var zentrierenY = (screen.height/2)-300;
		var pos = "left="+zentrierenX+",top="+zentrierenY; 
		window.open(PreMS + file,"print","width=660, height=600, resizable=no, scrollbars=yes, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);	
	}
	else {
	
	var zentrierenX = (screen.width/2)-350; 
		var zentrierenY = (screen.height/2)-300;
		var pos = "left="+zentrierenX+",top="+zentrierenY; 
		window.open(PreMOZ + file,"print","width=660, height=600, resizable=no, scrollbars=yes, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);	
	
	}
	
}

function popupWebcam(url)
{
	var zentrierenX = (screen.width/2)-300; 
	var zentrierenY = (screen.height/2)-245;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(url,"WebCam","width=600, height=495, resizable=no, scrollbars=yes, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}

function popupClip(url)
{
	var zentrierenX = (screen.width/2)-275; 
	var zentrierenY = (screen.height/2)-200;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(url,"clip","width=550, height=400, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}
			
function popup(file){
	var zentrierenX = (screen.width/2)-271; 
	var zentrierenY = (screen.height/2)-238;
	var pos = "left="+zentrierenX+",top="+zentrierenY; 
	window.open(file,"help","width=542, height=477, resizable=no, scrollbars=no, menubar=no, toolbar=no, directories=no, location=no, status=no, " + pos);
}


function GetImage(image,text,file,beschreibung){
	image.src = file ;
	text.innerHTML = beschreibung ;
}


function writeFlash(Path,Width,Height,Parameter) {
	document.write("<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' height='" +  Height + "' width='" + Width + "'>");
	document.write("<param name='movie' value='" + Path + Parameter + "'>");
	document.write("<param name='quality' value='best'>");
	document.write("<param name='play' value='true'>");
	document.write("<param name='menu' value='false'>");
	document.write("<param name='allowScriptAccess' value='always'>");
	document.write("<embed allowScriptAccess='always' menu='false' height='" + Height + "' pluginspage='http://www.macromedia.com/go/getflashplayer' src='" + Path + Parameter + "' type='application/x-shockwave-flash' width='" + Width + "' quality='best' play='true'>");
	document.write("</object>");
}

function writeFlashMenu(Path,Width,Height) {
	document.write("<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' width='" + Width + "' height='" + Height + "' id='menu' align='middle'>");
	document.write("<param name='allowScriptAccess' value='sameDomain' />");
	document.write("<param name='movie' value='"+ Path +"' />");
	document.write("<param name='quality' value='high' />");
	document.write("<param name='bgcolor' value='#4b87bc' />");
	document.write("<embed src='" + Path + "' quality='high' bgcolor='#4b87bc' width='" + Width + "' height='"+ Height +"' name='menu' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
	document.write("</object>");

}

function writeMediaplayer(Path,Width,Height,Autoplay) {

	document.write("<object id='MediaPlayer' classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95'   height='" + Height + "' width='" + Width + "'>");
	document.write("<param name='filename' value='"+ Path + "'>");
	document.write("<param name='autostart' value='" + Autoplay + "'>");
	document.write("<embed src='" + Path + "' width='" + Width + "' height='" + Height + "' autostart='" + Autoplay + "' />");
	document.write("</object>");

}

function writeQuicktime(Path,Width,Height,Autoplay) {

	document.write("<object classid='clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B' codebase='http://www.apple.com/qtactivex/qtplugin.cab' type='video/quicktime' height='" + Height + "' width='" + Width + "'>");
	document.write("<param name='src' value='" + Path + "'>");
	document.write("<param name='autoplay' value='" + Autoplay + "'>");
	document.write("<param name='controller' value=''>");						
	document.write("<embed height='" + Height + "' pluginspage='http://www.apple.com/quicktime/download/' src='" + Path + "' type='video/quicktime' width='" + Width + "' autoplay='" + Autoplay + "'>");
	document.write("</object>");
	
}
				
function setOrt(target,formular) {
	formular.FeratelSource.value = target.value.split("|")[0];
	if(target.value.split("|")[1] != undefined) {
		formular.Feld_Ort.value = target.value.split("|")[1];
	} else {
		formular.Feld_Ort.value = '';
	}
}

function setPackageGruppe(target,formular) {
	formular.Feld_Saison.value = target.value.split("|")[0];
	if(target.value.split("|")[1] != undefined) {
		formular.Feld_PackageGruppe.value = target.value.split("|")[1];
	} else {
		formular.Feld_PackageGruppe.value = '';
	}
}

function SelectOrt(wert,formular) {
	formular.FeratelSource.value = wert.split("|")[0];
	if(wert.split("|")[1] != undefined) {
		formular.Feld_Ort.value = wert.split("|")[1];
	} else {
		formular.Feld_Ort.value = '';
	}
	
	formular.submit();
}

function showOptions(){
	
	document.getElementById("feratelShowOptions").style.display =  "none";
	document.getElementById("feratelKategorien").style.display = "none";
	
	document.getElementById("feratelOptions").style.display = "block";
	document.getElementById("feratelHideOptions").style.display =  "block";
	
}

function hideOptions(){
	
	document.getElementById("feratelShowOptions").style.display =  "block";
	document.getElementById("feratelKategorien").style.display = "block";
	
	document.getElementById("feratelOptions").style.display = "none";
	document.getElementById("feratelHideOptions").style.display =  "none";
	
}

//Suche - Warten, Progress
function showQuickProgress()
{
	
	document.getElementById("quickbucher").style.display = "none";
	document.getElementById("quickwait").style.display = "block";
	document.getElementById("quickwaitimage").innerHTML = "<img src='images/snake.gif' border='0'>"; 

}

function counttrust(trustid){
	
	var xmlhttp=null;
	var url = 'http://www.kitzalps.com/de/gotrust.asp?ID=' + trustid;		
	
	if (window.XMLHttpRequest){xmlhttp=new XMLHttpRequest();} else if (window.ActiveXObject) {xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); }
	  
	if (xmlhttp!=null)
	  {
	 		xmlhttp.open("GET",url,true);	
	 		xmlhttp.send(null); 	  		
	  }	
	
}
