
// siebert.js Copyright (c)2003 Siebert Industrieelektronik GmbH.
var OpenPoint

var ns6
var ns6plus
var ns4
var ie6
var ie5
var win98
var opera

var dlwindow
var helpwindow
	
	function zoommap(page)
        {
		window.open(page,"map","height=560,width=540,toolbar=no,scrollbars=yes,location=no,directories=no,status=no");
        }

	function zoom(page)
        {
		window.open(page,"zoom","toolbar=no,scrollbars=yes,location=no,directories=no,status=yes");
        }
					
	function browser()
		{
		ns6plus = ((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) <=7 && (parseInt(navigator.appVersion) >4 )));
 	  	ns6 = ns6plus && (navigator.userAgent.indexOf("Netscape6") > 0)
     	ns4 = ((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) <5 ));
		win98 = ((navigator.appVersion.indexOf("MSIE") >0) && (navigator.appVersion.indexOf("Windows 98")>0));
	 	opera = (navigator.userAgent.indexOf("Opera") > 0)
		}

function ShowMenue(id, NN4, IE5, W3C) 
		{
		browser()
   		if (document.getElementById) 
			{
      		if (document.getElementById(id).style.visibility == "hidden") 
				{
        		if (!ns6plus)
       			{			
					if (!win98)
						{		
						if (!opera)
							{		
							document.getElementById(id).filters.revealTrans.Apply();
        					document.getElementById(id).filters.revealTrans.Play();
							}
						}
					}
					
          		eval("document.getElementById(id).style.visibility = \"" + IE5 + "\"");
      			}
    		}
   		else 
			{
       		if (document.layers) 
				{
          		document.layers[id].visibility = NN4;
       			} 
      		else 
				{
          		if (document.all) 
					{
               		eval("document.all." + id + ".style.visibility = \"" + IE5 + "\"");
            		}
        		}
    		}
		}

function HideMenue(id)
	{
    for (var mi=0; mi<=6; mi++)
		if(id!=mi)
			{
				eval("document.getElementById('menue'+mi).style.visibility = \"hidden\"");
			}
	}

function HideAllInt()
	{
	MM_showHideLayers('LayerD','','hide','LayerF','','hide','LayerNL','','hide','LayerA','','hide','LayerCH','','hide','LayerB','','hide','LayerDK','','hide','LayerFIN','','hide','LayerGB','','hide','LayerI','','hide','LayerL','','hide','LayerN','','hide','LayerS','','hide','LayerE','','hide','LayerCZ','','hide','LayerSA','','hide','LayerIRAN','','hide','LayerROK','','hide','LayerMAL','','hide','LayerSIN','','hide','LayerAUS','','hide');
	}
	
function MM_findObj(n, d) 
	{ //v4.0
  	var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  	if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  	for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  	if(!x && document.getElementById) x=document.getElementById(n); return x;
	}

function MM_showHideLayers() 
	{ //v3.0
  	var i,p,v,obj,args=MM_showHideLayers.arguments;
  	for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
	}

function MM_swapImgRestore() 
	{ //v3.0
  	var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
	}

function MM_preloadImages() 
	{ //v3.0
  	var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
	}

function MM_swapImage() 
	{ //v3.0
  	var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
	}
	
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function Check_Kontakt(language)
  	{	
		
	if (document.Infos.Firma)
	{
	chk = document.Infos.Firma.value;
  	if (chk == ""|| chk.length < 1)
  		{
      	switch(language) 
			{
 			case "d":
      		alert ('In "Firma" Eingabe erforderlich!');
			break;
 			case "e":
      		alert ('In "Company" entry required!');
			break;
 			case "f":
      		alert ('Entrée obligatoire dans "Societé"!');
			break;
 			case "nl":
      		alert ('In veld "Bedrijf" is invoer verplicht!');
			break;
			}
		document.Infos.Firma.focus();	
		return;
		}
	}
	
	if (document.Infos.Branche)
	{
	chk = document.Infos.Branche.value;
  	if (chk == " "|| chk.length < 1)
  		{
      	switch(language) 
			{
 			case "d":
      		alert ('In "Branche" Eingabe erforderlich!');
			break;
 			case "e":
      		alert ('In "Branch" entry required!');
			break;
 			case "f":
      		alert ('Entrée obligatoire dans "Branche"!');
			break;
 			case "nl":
      		alert ('In veld "Branche" is invoer verplicht!');
			break;
			}
		document.Infos.Branche.focus();
    	return;
		}
	}
  		  
	if (document.Infos.Name)
	{
 	chk = document.Infos.Name.value;
  	if (chk == ""|| chk.length < 1)
  		{
      	switch(language) 
			{
 			case "d":
      		alert ('In "Name, Vorname" Eingabe erforderlich!');
			break;
 			case "e":
      		alert ('In "Last, First Name" entry required!');
			break;
 			case "f":
      		alert ('Entrée obligatoire dans "Nom, Prénom"!');
			break;
 			case "nl":
      		alert ('In veld "Achternaam, Voornaame" is invoer verplicht!');
			break;
			}
		document.Infos.Name.focus();
    	return;
		//return false;
		}
	}
	
	if (document.Infos.Ort)
	{
	chk = document.Infos.Ort.value;
  	if (chk == ""|| chk.length < 1)
  		{
      	switch(language) 
			{
 			case "d":
      		alert ('In "Ort" Eingabe erforderlich!');
			break;
 			case "e":
      		alert ('In "City" entry required!');
			break;
 			case "f":
      		alert ('Entrée obligatoire dans "Ville"!');
			break;
 			case "nl":
      		alert ('In veld "Plaats" is invoer verplicht!');
			break;
			}
		document.Infos.Ort.focus();
    	return;
		//return false;
		}
  	}
	
	if (document.Infos.Land)
	{
	chk = document.Infos.Land.value;
  	if (chk == ""|| chk.length < 1)
  		{
      	switch(language) 
			{
 			case "d":
      		alert ('In "Land" Eingabe erforderlich!');
			break;
 			case "e":
      		alert ('In "Country" entry required!');
			break;
 			case "f":
      		alert ('Entrée obligatoire dans "Pays"!');
			break;
			}
		document.Infos.Land.focus();
    	return;
		//return false;
		}
  	}
  		  
	if (document.Infos.EMail)
	{
	chk = document.Infos.EMail.value;
  	if (chk == ""|| chk.length < 1)
  		{
      	switch(language) 
			{
 			case "d":
      		alert ('In "E-Mail" Eingabe erforderlich!');
			break;
 			case "e":
      		alert ('In "E-Mail" entry required!');
			break;
 			case "f":
      		alert ('Entrée obligatoire dans "E-Mail"!');
			break;
 			case "nl":
      		alert ('In veld "E-Mail" is invoer verplicht!');
			break;
			}
		document.Infos.EMail.focus();
    	return;
		//return false;
		}

	}

	if (document.Infos.Language)
	{
	chk = document.Infos.Language.value;
  	if (chk == " "|| chk.length < 1)
  		{
      	switch(language) 
			{
 			case "d":
      		alert ('In "Sprache" Eingabe erforderlich!');
			break;
 			case "e":
      		alert ('In "Language" entry required!');
			break;
 			case "f":
      		alert ('Entrée obligatoire dans "Langue"!');
			break;
 			case "nl":
      		alert ('In veld "Taal" is invoer verplicht!');
			break;
			}
		document.Infos.Language.focus();
    	return;
		}
	}

	if (document.Infos.Erklaerung)
	{
   	chk = document.Infos.Erklaerung.checked;
    if (chk == ""|| chk.length < 1)
        {
     	switch(language) 
			{
			case "d":
        	alert ('Bitte bestätigen Sie die Erklärung zu unseren Hinweisen zum Datenschutz!');
			break;
 			case "e":
        	alert ('Please confirm the statement to our notes to data protection!');
			break;
 			case "f":
        	alert ('Veuillez confirmer la déclaration relative à nos remarques sur la protection des données!');
			break;
 			case "nl":
        	alert ('Onze verklaring m.b.t. de bescherming van persoonsgegevens a.u.b. bevestigen!');
			break;
        		}
		document.Infos.Erklaerung.focus();   
      	return;
      	}
  	}
    document.Infos.submit();
	return;
	}

  // JS function for uncrypting spam-protected emails:
function UnCryptMailto(s) 
{	
	var n=0;
	var r="";
	for(var i=0; i < s.length; i++) 
	{
		n=s.charCodeAt(i);
		if (n>=8364) {n = 128;}
		r += String.fromCharCode(n-(3));
	}
	return r;
}

  // JS function for uncrypting spam-protected emails:
function linkTo_UnCryptMailto(s)	
{	//
 location.href=UnCryptMailto(s);
}

function open_help(page,hoehe)
      {
 	  helpwindow=window.open(page,"helpwindow",'dependent=yes,toolbar=no,scrollbars=no,width=320,height='+hoehe+',top=10,left=10,location=no,directories=no,status=no');
      }
 
 function open_dim(page,hoehe)
      {
 	  helpwindow=window.open(page,"helpwindow",'dependent=yes,toolbar=no,scrollbars=no,width=400,height='+hoehe+',top=10,left=10,location=no,directories=no,status=no');
      }
 
function open_download(page,menuPoint)
    {
    if(dlwindow)
	  	{
		dlwindow.close();
		}
	dlwindow=window.open(page,menuPoint,"dependent=yes,toolbar=no,scrollbars=yes,width=280,height=410,top=10,left=10,location=no,directories=no,status=no");
	}

function close_download()
    {
    if(dlwindow)
	  	{
	  	dlwindow.close();
		}
	}
function close_help()
    {
    if(helpwindow)
	  	{
	  	helpwindow.close();
		}
	}
