Hi fuli42,
Basically what jemminger and KevinAr18 said is true;
NS4 DOM is document.layers, IE4 is document.all, IE5 is document.all and document.getElementByID, and NS6 and other browsers are the W3C standard, document.getElementByID.
Stats at my sites still show a certain number of NS4 and IE4 users, so when I design scripts, I try to accomodate those browsers to a certain degree. I use a variant of a "cross-browser DOM" script I found in the Quickstart series, "DHTML and CSS for the World Wide Web" published by Peachpit press. I found this book to be a succint,helpful, and inexpensive guide when I was getting familiar with the ID DOM statndard. A typical variant of their script that I use is below:
d=document;
ID=(d.getElementById)?1:0;
ALL=(d.all)?1:0;
/*
you have to use this type of browser detection for NS4, because "document.layers" doesn't work in external script libraries for this browser
*/
NS4=(navigator.appName.indexOf("Netscape"

!=-1)&&(navigator.appVersion.indexOf("4"

!=-1);
IE5=ID&&ALL;
NS6=ID&!ALL;
/*
This function returns the various DOM references for style and non-style related objects.
*/
function DOM(objID,style){
if(style){
if(ID){
return (d.getElementById(objID).style);
}
if(ALL&!ID){
return (d.all[objID].style);
}
if(NS4){
return (d.layers[objID]);
}
}else{
if(ID){
return (d.getElementById(objID));
}
if(ALL&!ID){
return (d.all[objID]);
}
if(NS4){
return (d.layers[objID]);
}
}
}
/*
then, you can call this in other functions to supply the correct type of DOM reference without having to use multiple "if else" type conditionals. You might use this to say, change the visibilty if a style element with an ID of "example" like this:
*/
function showDiv(objID,state){
DOM(objID,1).visibility=state;
}
// and call it like this:
onmouseover="showDiv('example','hidden');"
The quickstart book also has a variant of this to deal with nested layers in NS4. Of course, there are lots of other little details of differing stylesheet support and HTML/JavaScript syntax when you are trying to adapt a single script to be "cross-browser" compatible, so the script above only does so much, but I find it to be a real time saver.
Hope this helps.
sundemon