function changeIt(ImageToChange, ImageToShow)
        {
if (document.images)
        {
document[ImageToChange].src = ImageToShow;
        }
        }
        if (document.images)
       {
        i1 = new Image;
        i1.src = "../images/deutsch/schule_h.gif";
        i2 = new Image;
        i2.src = "../images/deutsch/kurse_h.gif";
        i3 = new Image;
        i3.src = "../images/deutsch/freizeit_h.gif";
        i4 = new Image;
        i4.src = "../images/deutsch/unterkunft_h.gif";
        i5 = new Image;
        i5.src = "../images/deutsch/kurse_h.gif";
       }

function open_window(url){
        mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=670,height=550');
           }

function open_impressum(url){
        mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=450,height=440');
           }

function open_anzeige1(url){
        mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=340,height=450');
           }

function open_anzeige2(url){
        mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=300,height=200');
           }

function open_anzeige3(url){
        mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=150,height=500');
           }

function open_anzeige4(url){
        mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=290,height=130');
           }

function open_anzeige5(url){
        mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=285,height=100');
           }

function auswahl(element,url)
{
    if (document.form1.elements[element].checked == true)
    {
        parent.parent.frames[1].location.href="kkh_gesamt/suchliste.php";
        parent.parent.frames[2].location.href=url;
    }
}

function auswahl_reha(element,url)
{
    if (document.form1.elements[element].checked == true)
    {
        parent.parent.frames[1].location.href="reha/reha_suchliste.php";
        parent.parent.frames[2].location.href=url;
    }
}

function senddata(zahl,seite)
{
    //alert(seite);
    document.sendform.method = "post";
    document.sendform.action = seite;
    document.sendform.id.value = zahl;
    document.sendform.submit();
}

function checkdata_plz()
{
    for(i=0;i<document.form1.plz_von.value.length;++i)
    {
       if(document.form1.plz_von.value.charAt(i) < "0" || document.form1.plz_von.value.charAt(i) > "9")
       {
           alert("Bitte eine Zahl eingeben");
           document.form1.plz_von.value = "";
       }
    }
    for(i=0;i<document.form1.plz_bis.value.length;++i)
    {
       if(document.form1.plz_bis.value.charAt(i) < "0" || document.form1.plz_bis.value.charAt(i) > "9")
       {
           alert("Bitte eine Zahl eingeben");
           document.form1.plz_bis.value = "";
       }
    }
}

function checkdata_betten()
{
    for(i=0;i<document.form1.betten_von.value.length;++i)
    {
       if(document.form1.betten_von.value.charAt(i) < "0" || document.form1.betten_von.value.charAt(i) > "9")
       {
           alert("Bitte eine Zahl eingeben");
           document.form1.betten_von.value = "";
       }
    }
    for(i=0;i<document.form1.betten_bis.value.length;++i)
    {
       if(document.form1.betten_bis.value.charAt(i) < "0" || document.form1.betten_bis.value.charAt(i) > "9")
       {
           alert("Bitte eine Zahl eingeben");
           document.form1.betten_bis.value = "";
       }
    }
}

function wechsel(url1,url2)
{
    parent.frames[1].location.href=url1;
    parent.frames[2].location.href=url2;
}

function wechsel_neu(url1,url2)
{
    parent.frames[1].location.href=url1;
    parent.frames[2].location.href=url2;
}

function wechsel_1(url2)
{
   parent.frames[2].location.href=url2;
}

function back()
{
    history.back()
}

function senddata_drucken ()
{
    window.open("kkh_druck.php","Fenster1","width=750,height=400,screenX=0,screenY=0,resizable=yes,scrollbars=yes");
    document.form1.target = "Fenster1";
    document.form1.action = "kkh_druck.php";
    document.form1.submit();
}

function senddata_drucken_reha ()
{
    F1 = window.open("reha_druck.php","Fenster1","width=750,height=400,screenX=0,screenY=0,resizable=yes,scrollbars=yes");
    document.form1.target = "Fenster1";
    document.form1.action = "reha_druck.php";
    document.form1.submit();
}

function senddata_drucken_weiter ()
{
    F1 = window.open("weiter_druck.php","Fenster1","width=750,height=400,screenX=0,screenY=0,resizable=yes,scrollbars=yes");
    //document.form1.target = "Fenster1";
    //document.form1.action = "weiter_druck.php";
    //document.form1.submit();
}

function test(){
    alert("Schade, dass Sie das Bild nicht sehen wollen");                                                                  window.open("weiter_druck.php","Fenster1","width=750,height=400,screenX=0,screenY=0,resizable=yes,scrollbars=yes");
    //document.form1.target = "Fenster1";
    //document.form1.action = "weiter_druck.php";
    //document.form1.submit();
}


function schliessen()
{
   window.close();
}

function drucken()
{
   window.print();
}

function leer()
{
   var del = document.form1.del.value;
   if (del)
   {
      parent.frames[2].location.href = "../start_sel_kkh_gesamt.html";
   }
}

function weiter_leer()
{
   var del = document.form1.del.value;
   if (del)
   {
      parent.frames[2].location.href = "../weiterbildung/weiter_auswahl.php";
   }
}

function leer_reha()
{
   var del = document.form1.reha_del.value;
   if (del)
   {
       parent.frames[2].location.href = "../start_sel_reha.html";
   }
}

function zurueck_kkh()
{
   window.location.href = "../start_sel_kkh_gesamt.html";
}

function zurueck_reha()
{
   window.location.href = "../start_sel_reha.html";
}

function test_zurueck_neu()
{
   var b = document.form1.b.value;
   var d = parent.frames[1].location.href;
   var d_name = d.substr(58,d.length);
   alert(d_name);
   if (d_name=="suchliste.php"){
      window.location.href = "../start_sel_kkh_gesamt.html";
   }
   else{
       parent.frames[1].location.href = "../dka_nav_kkh_gesamt.php";
       window.location.href = "../start_sel_kkh_gesamt.html";
   }
}
