//****************************************************************
// Image-Change
//****************************************************************

sub1=new Image();
sub1.src="../../images/built/line_blau.gif";
sub2=new Image();
sub2.src="../../images/built/clear.gif";

team_hahn=new Image();
team_hahn.src="../../images/content/team_over-hahn.jpg";
team_reinermann=new Image();
team_reinermann.src="../../images/content/team_over-reinermann.jpg";
team_reinermann2=new Image();
team_reinermann2.src="../../images/content/team_over-reinermann2.jpg";
team_andersen=new Image();
team_andersen.src="../../images/content/team_over-andersen.jpg";
team_brockmann=new Image();
team_brockmann.src="../../images/content/team_over-brockmann.jpg";
team_gerneth=new Image();
team_gerneth.src="../../images/content/team_over-gerneth.jpg";
team_koethe=new Image();
team_koethe.src="../../images/content/team_over-koethe.jpg";
team_plaisier=new Image();
team_plaisier.src="../../images/content/team_over-plaisier.jpg";

team_gruppe=new Image();
team_gruppe.src="../../images/content/team_gruppe_neu.jpg";



function bw(Bildnr,Bildobjekt)
{
window.document.images[Bildnr].src=Bildobjekt.src
}


//****************************************************************
// Formular Input-Change
//****************************************************************
function inputColorChange(feldObject, new_style) 
{ 
feldObject.className=new_style;
}


//****************************************************************
// Popup
//****************************************************************
function popup(source, width, height)
{  
  window.open(source,"","width="+width+",height="+height+",resize=no,scrollbars=no,menubar=no,directories=no"); 
} 

//****************************************************************
// Popup - Dynamisches HTML
//****************************************************************
var popup_var="", num=0; 
function popup_dyn(x,y,titel,bild) 
{ 
popup_var=window.open("", num, "width="+(x+30)+",height=600") 
popup_var.document.write("<html>"); 
popup_var.document.write("<head><link rel='STYLESHEET' type='text/css' href='../../scripts/styles.css'> "); 
popup_var.document.write("<title>Hahn, Reinermann & Partner | "+titel+"</title></head>"); 
popup_var.document.write("<body scroll='auto' style='margin-top:20px; margin-bottom:20px'>"); 
popup_var.document.write("<center><img src="+bild+" width="+x+" height="+y+"><p>"); 
popup_var.document.write("<a href='javascript:window.close()' onfocus='blur()'><strong>Fenster schliessen</strong></a></center>"); 
popup_var.document.write("</body></html>"); 
num++; 
} 
 
//****************************************************************
// FORMULAR-CHECK ( Kontakt )
//****************************************************************

function checkform()

{
   if(document.mailform.anrede.value == "--")
   {
    alert("Bitte wählen Sie eine Anrede!");
    document.mailform.anrede.focus();
    return false;
   } 
   
   if(document.mailform.name.value == "")
   {
    alert("Bitte geben Sie Ihren Nachnamen an!");
    document.mailform.name.focus();
    return false;
   } 
	
	
   if(document.mailform.adresse.value == "")
   {
    alert("Bitte geben Sie eine Anschrift ein!");
    document.mailform.adresse.focus();
    return false;
   } 

   if ((document.mailform.plz.value=="")) 
   {
   alert("Bitte geben Sie eine PLZ ein!");
   document.mailform.plz.focus();
   return false; 
   }  
   
   if ((document.mailform.ort.value=="")) 
   {
   alert("Bitte geben Sie einen Ort ein!");
   document.mailform.ort.focus();
   return false; 
   }
   
   if(document.mailform.land.value == "")
   {
    alert("Bitte geben Sie Ihr Land an!");
    document.mailform.land.focus();
    return false;
   } 
   
    if ((document.mailform.fon.value=="")) 
   {
   alert("Bitte geben Sie eine Telefonnummer ein!");
   document.mailform.fon.focus();
   return false; 
   }    
     
    if ((document.mailform.email.value.indexOf('@', 0) == -1) || (document.mailform.email.value.indexOf('.') == -1)) 
   {
   alert("Bitte geben Sie eine gültige Email-Adresse ein!");
   document.mailform.email.focus();
   return false; 
   }  

     else
   {document.mailform.submit();
   return document.mailform.submit()}
}

//****************************************************************
// FORMULAR-CHECK ( Newsletter )
//****************************************************************

function checkform_newsletter()

{     
    if ((document.mailform.email.value.indexOf('@', 0) == -1) || (document.mailform.email.value.indexOf('.') == -1)) 
   {
   alert("Bitte geben Sie eine gültige Email-Adresse ein!");
   document.mailform.email.focus();
   return false; 
   }  

     else
   {document.mailform.submit();
   return document.mailform.submit()}
}



//****************************************************************
// Suche-Check
//****************************************************************
function checkSearch(){
  if(document.frmSearch.term.value == ""){
    alert("Sie müssen einen Suchbegriff eingeben!");
    return false;
  }
  document.frmSearch.submit();
}
