// JavaScript Document


//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	// FUNKTION Bundesländer Highlighten
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

	// Bundesländer Karte
	function showBundesland(id,bundesland) {
		document.getElementById(id).src = "_img/karten/"+bundesland+".jpg";
	}
	
	function hideBundesland(id,bundesland) {		
		document.getElementById(id).src = "_img/karten/deutschlandkarte.jpg";		
	}


//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	// FUNKTION Navi Mouseover Mouseout
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

	function setHover(id,path) {
		//alert(id + path);
		var highlight = document.getElementById(id);		
		highlight.src = path+"_img/navi/"+id+"_h.jpg";
	}
	function killHover(id,path) {	
		var highlight = document.getElementById(id);		
		highlight.src = path+"_img/navi/"+id+"_n.jpg";
	}	
	function setHoverSubnavi(id,path) {	
		var highlight = document.getElementById(id);		
		highlight.src = path+"_img/navi/subnavi/"+id+"_h.jpg";
	}
	function killHoverSubnavi(id,path) {	
		var highlight = document.getElementById(id);		
		highlight.src = path+"_img/navi/subnavi/"+id+"_n.jpg";
	}

//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	// FUNKTION Weiterleitung
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

	function openDiv(id) {

		document.getElementById(id).style.display = 'block';
				
		if(navigator.appName == "Microsoft Internet Explorer") { // is IE
		
		var opIntervall=100;
		var opStep= 10;		
		
			currOpacity=document.getElementById(id).filters.alpha.opacity * 1;	
			currOpacity += opStep;
			document.getElementById(id).filters.alpha.opacity = currOpacity;
		
			 if (currOpacity < 100) {	 
				if(id=="weiterempfehlen") window.setTimeout("openDiv('weiterempfehlen')",opIntervall);
				if(id=="hinweis") window.setTimeout("openDiv('hinweis')",opIntervall);
				if(id=="topArbeitgeber") window.setTimeout("openDiv('topArbeitgeber')",opIntervall);
			 }	
		
		} else { // is FF
		
			var opIntervall=1;
			var opStep= .05;
		
			 currOpacity=document.getElementById(id).style.opacity * 1;	
			 currOpacity += opStep;
			 document.getElementById(id).style.opacity = currOpacity;
		
			 if (currOpacity < 1) {	 
				if(id=="weiterempfehlen") setTimeout("openDiv('weiterempfehlen')",opIntervall);
				if(id=="hinweis") setTimeout("openDiv('hinweis')",opIntervall);
				if(id=="topArbeitgeber") setTimeout("openDiv('topArbeitgeber')",opIntervall);
			 }				
		}		
		
	}
	
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	// FUNKTION Videos groß anzeigen
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

	function openVideo(id,videofile,path,headline) {		
		
		document.getElementById(id).style.display = 'block';
		if(videofile != "bvr_04_06_09") document.getElementById("video").style.display = 'none';
		
		//if(headline != "") document.getElementById("videoHeadline").innerHTML = "<h1><center>"+headline+"</center></h1>";
		//else if(headline == undefined) document.getElementById("videoHeadline").innerHTML = " ";

		if(videofile == "bvr_04_06_09") var so = new SWFObject(path+"_flash/vr_videos_bvr.swf?videopath="+path+"&amp;videofilename="+videofile+".flv&amp;lang=''","mymovie","500","256","8","", true);
		else var so = new SWFObject(path+"_flash/vr_videos.swf?videopath="+path+"&amp;videofilename="+videofile+".flv&amp;lang=''","mymovie","320","256","8","", true);
		//firstmovie.setAttribute('xiRedirectUrl', 'http://<? echo $_SERVER['HTTP_HOST'].$_SERVER['SCRIPT_NAME']; ?>'); // must be the absolute URL to your site			
		so.addParam("wmode", "transparent");
		if(videofile == "bvr_04_06_09") so.write("videoContainer_bvr");
		else so.write("videoContainer");
	
	}

//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	// FUNKTION Videos groß anzeigen
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

	function closeVideo(which) {
		if(which != "bvr") document.getElementById('videoBox').style.display = 'none';
		else document.getElementById('videoBox_bvr').style.display = 'none';
		if(which != "bvr") document.getElementById('video').style.display = 'block';
		onLoad=location.reload();
	}
	
	
	function resize_window(width, height){
		window.moveTo(2,2);
		window.resizeTo(width, height);
	}