   d=document;l=d.layers;op=navigator.userAgent.indexOf('Opera')!=-1;px='px';
   function gE(e,f){if(l){f=(f)?f:self;var V=f.document.layers;if(V[e])return V[e];for(var W=0;W<V.length;)t=gE(e,V[W++]);return t;}if(d.all)return d.all[e];return d.getElementById(e);}
	 function swap()
	 {
	   swp = gE(swap.arguments[0]);
     swp.src = swap.arguments[1];
	 }

	
	function chkFormular()

	{
		var Datum = new Date();
		var Jahr = Datum.getFullYear();

	     if(document.kontakt.familienname.value == "")
	      {
	      alert("Bitte nennen Sie uns doch Ihren Namen.");
	      document.kontakt.familienname.focus();
	      return false;
	      } 
		if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(document.kontakt.mailadresse.value)))
	      {
	      alert("Bitte geben Sie eine korrekte E-Mail-Adresse ein.");
	      document.kontakt.mailadresse.focus();
	      return false;
	      } 
	    if(document.kontakt.nachricht.value == "")
	      {
	      alert("Bitte geben Sie einen Mitteilungs-Text ein.");
	      document.kontakt.nachricht.focus();
	      return false;
	      } 
	    if(document.kontakt.spamschutz.value != Jahr )
	      {
	      alert("Bitte geben Sie die aktuelle Jahreszahl (vierstellig) ein. Diese Maßnahme ist leider notwendig, um Spammails zu vermeiden.");
	      document.kontakt.spamschutz.focus();
	      return false;
	      } 
	} // check formular


	function PanoramafensterOeffnen (Adresse) {
	  MeinFenster = window.open(Adresse, "x", "width=450, height=350");
	  MeinFenster.focus();
	}

	function BildfensterOeffnen (Adresse) {
	  MeinFenster = window.open(Adresse, "Zweitfenster", "width=660, height=660, resizable=yes");
	  MeinFenster.focus();
	}

	function FensterOeffnen (Adresse) {
	  MeinFenster = window.open(Adresse, "Zweitfenster", "scrollbars=yes,width=580,height=700");
	  MeinFenster.focus();
	}

	function MM_openBrWindow(theURL,winName,features) { //v2.0
	  window.open(theURL,winName,features);
	}



	/***********************************************
	* Switch Menu script- by Martial B of http://getElementById.com/
	* Modified by Dynamic Drive for format & NS4/IE4 compatibility
	* Visit http://www.dynamicdrive.com/ for full source code
	***********************************************/

	var persistmenu="yes" //"yes" or "no". Make sure each SPAN content contains an incrementing ID starting at 1 (id="sub1", id="sub2", etc)
	var persisttype="sitewide" //enter "sitewide" for menu to persist across site, "local" for this page only

	if (document.getElementById){ //DynamicDrive.com change
	document.write('<style type="text/css">\n')
	document.write('.submenu{display: none;}\n')
	document.write('</style>\n')
	}

	function SwitchMenu(obj){
		if(document.getElementById){
		var el = document.getElementById(obj);
		var ar = document.getElementById("navigation").getElementsByTagName("div"); //DynamicDrive.com change
			if(el.style.display != "block"){ //DynamicDrive.com change
				for (var i=0; i<ar.length; i++){
					if (ar[i].className=="submenu") //DynamicDrive.com change
					ar[i].style.display = "none";
				}
				el.style.display = "block";
			}else{
				el.style.display = "none";
			}
		}
	}

	function get_cookie(Name) { 
	var search = Name + "="
	var returnvalue = "";
	if (document.cookie.length > 0) {
	offset = document.cookie.indexOf(search)
	if (offset != -1) { 
	offset += search.length
	end = document.cookie.indexOf(";", offset);
	if (end == -1) end = document.cookie.length;
	returnvalue=unescape(document.cookie.substring(offset, end))
	}
	}
	return returnvalue;
	}

	function onloadfunction(){
	if (persistmenu=="yes"){
	var cookiename=(persisttype=="sitewide")? "switchmenu" : window.location.pathname
	var cookievalue=get_cookie(cookiename)
	if (cookievalue!="")
	document.getElementById(cookievalue).style.display="block"
	}
	}

	function savemenustate(){
	var inc=1, blockid=""
	while (document.getElementById("sub"+inc)){
	if (document.getElementById("sub"+inc).style.display=="block"){
	blockid="sub"+inc
	break
	}
	inc++
	}
	var cookiename=(persisttype=="sitewide")? "switchmenu" : window.location.pathname
	var cookievalue=(persisttype=="sitewide")? blockid+";path=/" : blockid
	document.cookie=cookiename+"="+cookievalue
	}

	if (window.addEventListener)
	window.addEventListener("load", onloadfunction, false)
	else if (window.attachEvent)
	window.attachEvent("onload", onloadfunction)
	else if (document.getElementById)
	window.onload=onloadfunction

	if (persistmenu=="yes" && document.getElementById)
	window.onunload=savemenustate


