//-------------------- Fenster mit automatischer Anpassung ---------------------------------

function popupWindow(url) {
  window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=100,height=100,screenX=150,screenY=150,top=150,left=150')
}




//-------------------- Tabellen bg farbe ---------------------------------

function zellebg(obj, farbe)
{
	obj.style.backgroundColor=farbe
}

//-------------------- E-Mail prüfen -------------------------------------

// Einbau in <form> :  onSubmit="return chkFormular()"
function chkFormular()
    {

if(document.Formular.url.value == "")  {
   alert("Bitte geben Sie eine URL ein...");
   document.Formular.url.focus();
   return false;
  }
	
if(document.Formular.email.value.indexOf('@') == -1)
    {
     alert("keine korrekte E-Mail!\nno correct E-Mail\npas d'e-mail correct\nningún email correcto\nnenhum email correto!");
     document.Formular.email.focus();
     return false;
    }
	if(document.Formular.email.value.indexOf('.') == -1)
    {
     alert("keine korrekte E-Mail!\nno correct E-Mail\npas d'e-mail correct\nningún email correcto\nnenhum email correto");
     document.Formular.email.focus();
     return false;
    }
   	var zeichen="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLKMNOPQRSTUVWXYZ@.-";
          	  eingabe=document.Formular.email.value;
          	  laenge=eingabe.length;
          	  	for(y=0; y<100; y++){
          	   		z=eingabe.charAt(y);
          	   	if(zeichen.indexOf(z)== -1){
          	    alert("Bitte keine Sonderzeichen in die E-Mail Adresse eintragen\ndo not use special characters\ndes caractères spéciaux ne pas utiliser\nno utilice los caracteres especiales\nnão use caráteres especiais");
          	    document.Formular.email.value=="";
          	    document.Formular.email.focus();
          	    return false
          		}
   			}

if(document.Formular.kategorie.value == "%%")  {
   alert("Bitte geben Sie eine Kategorie ein...");
   document.Formular.kategorie.focus();
   return false;
  }

			
	}
	
// Wiederholung fuer Formular5


function chkFormular5()
    {

if(document.Formular1.email.value.indexOf('@') == -1)
    {
     alert("keine korrekte E-Mail!\nno correct E-Mail\npas d'e-mail correct\nningún email correcto\nnenhum email correto!");
     document.Formular1.email.focus();
     return false;
    }
	if(document.Formular1.email.value.indexOf('.') == -1)
    {
     alert("keine korrekte E-Mail!\nno correct E-Mail\npas d'e-mail correct\nningún email correcto\nnenhum email correto");
     document.Formular1.email.focus();
     return false;
    }
   	var zeichen="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLKMNOPQRSTUVWXYZ@.-";
          	  eingabe=document.Formular1.email.value;
          	  laenge=eingabe.length;
          	  	for(y=0; y<100; y++){
          	   		z=eingabe.charAt(y);
          	   	if(zeichen.indexOf(z)== -1){
          	    alert("Bitte keine Sonderzeichen in die E-Mail Adresse eintragen\ndo not use special characters\ndes caractères spéciaux ne pas utiliser\nno utilice los caracteres especiales\nnão use caráteres especiais");
          	    document.Formular1.email.value=="";
          	    document.Formular1.email.focus();
          	    return false
          		}
   			}


	}

//-------------------- function chkFormular0() -------------------------------------
// Einbau in <form> :  onSubmit="return chkFormular0()"
function chkFormular0()
{
if(document.Formular0.suche.value == "")  {
   alert("Bitte machen Sie eine Eingabe \nMake please input \nFaites s'il vous plaît l'entrée \nHaga por favor la entrada de información \nFaça por favor a entrada");
   document.Formular0.suche.focus();
   return false;
  }

}



//-------------------- function chkFormular1() -------------------------------------
// Einbau in <form> :  onSubmit="return chkFormular1()"
function chkFormular1()
{
if(document.Formular.str_objekt.value == "")  {
   alert("Bitte die rot markierten Felder ausfüllen \nFill out please the red marked fields \nVeuillez remplir les champs marqués rouge \nQuiere llenar los campos señalados rojo \nQueiram preencher os campos marcados vermelho");
   document.Formular.str_objekt.focus();
   return false;
  }

if(document.Formular.plz_objekt.value == "")  {
   alert("Bitte die rot markierten Felder ausfüllen \nFill out please the red marked fields \nVeuillez remplir les champs marqués rouge \nQuiere llenar los campos señalados rojo \nQueiram preencher os campos marcados vermelho");
   document.Formular.plz_objekt.focus();
   return false;
  }

if(document.Formular.ort_objekt.value == "")  {
   alert("Bitte die rot markierten Felder ausfüllen \nFill out please the red marked fields \nVeuillez remplir les champs marqués rouge \nQuiere llenar los campos señalados rojo \nQueiram preencher os campos marcados vermelho");
   document.Formular.ort_objekt.focus();
   return false;
  }
 
if(document.Formular.vorname_kontakt.value == "")  {
   alert("Bitte die rot markierten Felder ausfüllen \nFill out please the red marked fields \nVeuillez remplir les champs marqués rouge \nQuiere llenar los campos señalados rojo \nQueiram preencher os campos marcados vermelho");
   document.Formular.vorname_kontakt.focus();
   return false;
  }
  
if(document.Formular.nachname_kontakt.value == "")  {
   alert("Bitte die rot markierten Felder ausfüllen \nFill out please the red marked fields \nVeuillez remplir les champs marqués rouge \nQuiere llenar los campos señalados rojo \nQueiram preencher os campos marcados vermelho");
   document.Formular.nachname_kontakt.focus();
   return false;
  }  
 
if(document.Formular.tel_kontakt.value == "")  {
   alert("Bitte die rot markierten Felder ausfüllen \nFill out please the red marked fields \nVeuillez remplir les champs marqués rouge \nQuiere llenar los campos señalados rojo \nQueiram preencher os campos marcados vermelho");
   document.Formular.tel_kontakt.focus();
   return false;
  }  
 
 }
 
 //-------------------- function chkFormular3() -------------------------------------
 // Einbau in <form> :  onSubmit="return chkFormular3()"
 function chkFormular3()

{
    	var zeichen="0123456789";
           	  eingabe=document.zielsuche.klpreis.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.zielsuche.klpreis.value=="";
           	    document.zielsuche.klpreis.focus();
           	    return false
           		}
   			}

 }
 
//-------------------- function chkFormular2() -------------------------------------
// Einbau in <form> :  onSubmit="return chkFormular2()"
function chkFormular2()
{
    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preis1.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preis1.value=="";
           	    document.Formular2.preis1.focus();
           	    return false
           		}
   			}


    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preis2.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preis2.value=="";
           	    document.Formular2.preis2.focus();
           	    return false
           		}
   			}



    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preis3.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preis3.value=="";
           	    document.Formular2.preis3.focus();
           	    return false
           		}
   			}


    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preis4.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preis4.value=="";
           	    document.Formular2.preis4.focus();
           	    return false
           		}
   			}


    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preis5.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preis5.value=="";
           	    document.Formular2.preis5.focus();
           	    return false
           		}
   			}

    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preistier.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preistier.value=="";
           	    document.Formular2.preistier.focus();
           	    return false
           		}
   			}


    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preistier.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preistier.value=="";
           	    document.Formular2.preistier.focus();
           	    return false
           		}
   			}
   			
    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preis6.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preis6.value=="";
           	    document.Formular2.preis6.focus();
           	    return false
           		}
   			}
   			
    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preiswash.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preiswash.value=="";
           	    document.Formular2.preiswash.focus();
           	    return false
           		}
   			}   			
   			
    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preisstrom.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preisstrom.value=="";
           	    document.Formular2.preisstrom.focus();
           	    return false
           		}
   			}
   			
   			
    	var zeichen="0123456789,.";
           	  eingabe=document.Formular2.preissonst.value;
           	  laenge=eingabe.length;
           	  	for(y=0; y<100; y++){
           	   		z=eingabe.charAt(y);
           	   	if(zeichen.indexOf(z)== -1){
           	    alert("Bitte nur Zahlen eingeben... \nPlease only input numbers... \nUne demande qu'à des nombres entrer... \nUna demanda que a números entrar... \num pedido que à números entrar...");
           	    document.Formular2.preissonst.value=="";
           	    document.Formular2.preissonst.focus();
           	    return false
           		}
   			}
   			
}
//-------------------- Sprungmenue ---------------------------------------

//--einfügen <select name="menuname" onChange="MM_jumpMenu('parent',this,0)">

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}



//-------------------- alert  -------------------------------------

function MM_popupMsg(msg) { //v1.0
  alert(msg);
}


//-------------------- check zeichen -------------------------------------
  function CheckLen(Target){
   StrLen = Target.value.length
   if (StrLen == 1 && Target.value.substring(0,1) == " ")
    {Target.value = ""; StrLen = 0}
 
   if (StrLen > 130 )
    {Target.value = Target.value.substring(0,130)
     CharsLeft = 0}
   else{CharsLeft = 130 - StrLen}
   document.Form.Anzahl.value = CharsLeft
  }
 

// anpassen im Formular
//<Form name="Form">
// Sie haben noch: 
// <input type="text" name="Anzahl" size="3" maxlength="3" readonly>
// Zeichen<br>
// <textarea rows="5" 
//  cols="35" onChange="CheckLen(this)" 
//  onFocus="CheckLen(this)" onKeyDown="CheckLen(this)" 
//  onKeyUp="CheckLen(this)" wrap="VIRTUAL" >
// </textarea>
//</form>





//-------------------- Grafik Navigation -------------------------------------

var t=new Array(3);
var b1=b2=b3=b4=b5=b6=b7=b8=b9=b10=b11=b12=b13=b14=b15=b16=b17=0;
function cp(b){if(document.images){if((t[2])&&(t[2]==b)){t[0]=t[2];t[1]=t[3]}else{t[0]=b;t[1]=b.src;t[4]=b.src.lastIndexOf('.');b.src=b.src.substring(0,t[4])+'_'+b.src.substring(t[4])}}return;}
function sp(){if(document.images){if((t[2])&&(t[2]!=t[0])){t[2].src=t[3]}t[2]=t[0];t[3]=t[1];}focus();return;}
function op(){if(document.images){if(t[0]!=t[2])t[0].src=t[1]}}


//-------------------- Netscape Bug beseitigen -------------------------------

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);


//--------------------Grafiken vorladen---------------------------------------

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];}}
}

//-------------------- Fenster öffnen ----------------------------------------


function BildFenster0 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=yes,width=700,height=600, left=20, top=20,resizable=yes");
}

function BildFenster1 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=yes,width=500,height=300, left=0, top=0,resizable=yes");
}

function BildFenster2 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=yes,width=800,height=600, left=0, top=0,resizable=yes");
}

function BildFenster3 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=320,height=450, left=40, top=40,resizable=yes");
}

function BildFenster4 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=400,height=450, left=40, top=40,resizable=yes, scrollbars=yes" );
}

function BildFenster5 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=300,height=300, left=40, top=40,resizable=yes" );
}

function neue_branche (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=400,height=300, left=400, top=300,resizable=yes" );
}

function geo (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=440,height=525, left=40, top=40,resizable=yes, margintop=0" );
}

function BildFenster9 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=320,height=360, left=0, top=0,resizable=yes");
}

function BildFenster10 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=800,height=600, left=0, top=0,resizable=yes, scrollbars=yes" );
}

function BildFenster11 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=460,height=300, left=40, top=40,resizable=yes, scrollbars=no" );
}

function BildFenster12 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=no,width=800,height=550, left=0, top=0,resizable=yes, scrollbars=yes" );
}

//--------------------popup mit Seitenaufruf----------------------------------
//----in body tack einfügen --------------------------------------------------
//onLoad="MM_openBrWindow('newswin.asp','news','resizable=1,toolbar=0,status=0,scrollbars=0,width=400,height=300')

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);  
}
//---------------------------------------------------------------------------
//--Aufruflink-- <a href="javascript:popup('datei.asp')">--------------------
function popup (Bild1)
{
iwin = window.open (Bild1, "iwin","menu=0,toolbar=0,scrollbars=0,resizable=1,width=300,height=250,left=80,top=80");
}

//---------------------------------------------------------------------------

//############################################################################
//onClick="clearEmailBox()" Funktionsaufruf für clear
//############################################################################


//------------------------input leeren----------------------------------------
function clearEmailBox1()
{
if (document.Formular1.email.value = "ihre@adresse"){
	document.Formular1.email.value = ""
	}
}


//----------------------------------------------------------------------------



//------------------------input leeren----------------------------------------
function clearEmailBox()
{
if (document.Formular.email.value = "E-Mail"){
	document.Formular.email.value = ""
	}
}


//----------------------------------------------------------------------------

//------------------------input leeren----------------------------------------
function clearOrtaBox()
{
if (document.Formular.orta.value = "Ort"){
	document.Formular.orta.value = ""
	}
}


//----------------------------------------------------------------------------

//------------------------input leeren----------------------------------------
function clearbezeichnungBox()
{
if (document.Formular.bezeichnung.value = "SUCHBEGRIFF"){
	document.Formular.bezeichnung.value = ""
	}
}


//----------------------------------------------------------------------------

//------------------------input leeren----------------------------------------
function clearOrtBox()
{
if (document.Formular.ort.value = "Ort"){
	document.Formular.ort.value = ""
	}
}


//----------------------------------------------------------------------------

//------------------------input leeren----------------------------------------
function clearPLZBox()
{
if (document.Formular.plz.value = "PLZ"){
	document.Formular.plz.value = ""
	}
}

//----------------------------------------------------------------------------

//------------------------input leeren----------------------------------------
function clearPLZsuchBox()
{
if (document.Formular.plzsuch.value = "PLZ"){
	document.Formular.plzsuch.value = ""
	}
}

//----------------------------------------------------------------------------

//------------------------input leeren----------------------------------------
function clearPreisBox()
{
if (document.Formular.prtag.value = "Preis"){
	document.Formular.prtag.value = ""
	}
}


//----------------------------------------------------------------------------

//------------------------input leeren----------------------------------------
function clearwkdnrBox()
{
if (document.Formular.wkdnr.value = "hier Ihre Kundennummer"){
	document.Formular.wkdnr.value = ""
	}
}


//----------------------------------------------------------------------------


//------------------------script für systran ---------------------------------


function RAS(n)
{
document.TRANS.elements[n].value="";
}

function BildFenster1 (Bild0)
{
iwin = window.open (Bild0, "iwin","menu=no,toolbar=no,scrollbars=yes,width=750,height=500, left=20, top=20,resizable=yes");
}



//----------------------------------------------------------------------------
//* ---------- Funktion Frame dazuladen ---------- */


//if (window == top) top.location.href = "http://www.fewohaus.de/asp/index.asp";



//----------------------------------------------------------------------------


//* ---------- Funktion Copyright ---------- */
//if (document.layers)
//{
//window.captureEvents(Event.MOUSEDOWN | Event.MOUSEUP)
//window.onmousedown=rightclick;
//window.onmouseup=rightclick;
//function rightclick(e)
//	{
//	if (e.which == 3)
//		{alert('Copyright 2001 by onlineprojekt GbR');return false;}
//	else
//		{return true;}
//	}
//}
//
//if (document.all)
//{
//function click()
//	{
//	if (event.button==2)
//		{alert('Copyright 2002 by onlineprojekt GbR')}
//	if (event.button==3)
//		{alert('Copyright 2002 by onlineprojekt GbR')}
//	}
//document.onmousedown=click
//}
//--------------------              ------------------------------------------
