- No object detection, just
- Code that is written only for IE4+ and/or Netscape 4. One can tell this
by checking to see if the code uses IE's
document.alland/or Netscape 4's
document.layerswithout using DOM1+'s
document.allis used to detect if a browser is IE. To work with legacy web pages many other browsers support document.all, so you should only test for it if you intend to use it to support browsers that don't properly support the DOM1+ methods that have rendered it obsolete.
with(object)is used. It is slow and can cause unexpected behavior, and you can easily get its benefits without its problems by assigning the
objectto a new variable.
eval()is used more than once or twice. It's slow and it is almost always not needed.
Last update: 2006-10-06