You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
var maxOrdnungen=Ds.length-1;
|
|
|
|
|
var maxFelder=Ds[1].length -1;
|
|
|
|
|
NS4 = (document.layers)? 1: 0;
|
|
|
|
|
IE4=(document.all)?1:0;
|
|
|
|
|
ver4=(NS4 ||IE4) ? 1: 0;
|
|
|
|
|
if (document.getElementsByTagName && !document.all)
|
|
|
|
|
document.all = document.getElementsByTagName("*"); //f<EFBFBD>r NS6
|
|
|
|
|
var zs="";
|
|
|
|
|
var ebene=0;
|
|
|
|
|
|
|
|
|
|
function init_btn(btnOjekt,elter,ausgewaehlt)
|
|
|
|
|
{
|
|
|
|
|
zs="<select name=\""+btnOjekt.name+"\">";
|
|
|
|
|
zs+="<option value=''>----Keine Einschr<EFBFBD>nkung-----</option>";
|
|
|
|
|
//alert(elter);
|
|
|
|
|
if(elter=="null") elter=suche_root();
|
|
|
|
|
zs+=suche_kinder(elter,ausgewaehlt);
|
|
|
|
|
zs+="</select>";
|
|
|
|
|
//alert(ausgewaehlt+" "+zs);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (NS4)
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
with (document.Formular.document) {
|
|
|
|
|
open();
|
|
|
|
|
write(zs);
|
|
|
|
|
close();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
document.all.Formular.innerHTML=zs;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function suche_kinder(elter,ausgewaehlt)
|
|
|
|
|
{
|
|
|
|
|
var z="";
|
|
|
|
|
ebene++;
|
|
|
|
|
z+="<optgroup>"
|
|
|
|
|
//alert(elter);
|
|
|
|
|
for (var i=1;i<=maxOrdnungen;i++)
|
|
|
|
|
{
|
|
|
|
|
if(Ds[i][1]==elter)
|
|
|
|
|
{
|
|
|
|
|
z+="<option value='"+Ds[i][2]+"'";
|
|
|
|
|
if(Ds[i][2]==ausgewaehlt) z+=" selected";
|
|
|
|
|
z+=">";
|
|
|
|
|
for (var j=1;j<=ebene;j++) z+=" ";
|
|
|
|
|
z+=Ds[i][3]+"</option>";
|
|
|
|
|
z+=suche_kinder(Ds[i][2],ausgewaehlt);
|
|
|
|
|
zs+=z;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
ebene--;
|
|
|
|
|
z+="</optgroup>"
|
|
|
|
|
return(z);
|
|
|
|
|
}
|
|
|
|
|
function suche_root()
|
|
|
|
|
{
|
|
|
|
|
var z=0;
|
|
|
|
|
for (var i=1;i<=maxOrdnungen;i++)
|
|
|
|
|
{
|
|
|
|
|
if(Ds[i][1]=="" || Ds[i][1]=="null")
|
|
|
|
|
{
|
|
|
|
|
//alert(z);
|
|
|
|
|
z=i;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if(z==0) z=1;
|
|
|
|
|
return(Ds[z][2]);
|
|
|
|
|
}
|