DOM: which version is most supported?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Robert

    DOM: which version is most supported?

    Hi,

    which DOM version (level) should I learn? I've seen that there is a DOM
    level 3, but is there any support for it already?

    --
    Rob
  • Keith Bowes

    #2
    Re: DOM: which version is most supported?

    Robert wrote:[color=blue]
    > Hi,
    >
    > which DOM version (level) should I learn? I've seen that there is a DOM
    > level 3, but is there any support for it already?
    >[/color]

    DOM 0 is supported by every JavaScript-enabled browser that I know of.

    DOM 1 has pretty good support: Mozilla, Netscape 6+, IE/Win 6+ (and to
    a good degree in 5.x), Opera (5+, IIRC), Safari/Konqueror, etc. That
    really should be your primary target for learning.

    DOM2 is still pretty spotty. Mozilla supports it all, IIRC. IE
    supports only what was taken from the IE DOM. I'm pretty sure than
    Safari and Opera do style manipulation and events pretty well.

    DOM3 it seems is minimally supported. IIRC, Mozilla supports part of it
    but nothing else does.

    Comment

    • DU

      #3
      Re: DOM: which version is most supported?

      Robert wrote:[color=blue]
      > Hi,
      >
      > which DOM version (level) should I learn? I've seen that there is a DOM
      > level 3, but is there any support for it already?
      >[/color]

      DOM 1 attributes and methods in various interfaces are overall very well
      supported in modern browsers: MSIE 6 for Windows, Mozilla 1.x, Netscape
      7.x, Safari 1.x, Konqueror 3.x, Opera 7.x, K-meleon 0.7+, Galeon 1.2+, etc..

      DOM 2 attributes and methods are also fairly well supported by modern
      browsers. All major browser manufacturers (Mozilla, Microsoft, Apple,
      Opera) claim to support 100% of DOM 2 HTML and to support DOM 2 Core
      very well.
      Several noticeable issues on DOM 2 interfaces:
      - MSIE 6 does not support DOM 2 Events interface. Except maybe a few
      attributes. Mostly because implementing it would have necessarly implied
      important changes in the underlying os. Mozilla 1.x and Opera 7.x
      support DOM 2 Events very well.
      - Mozilla still has issues for DOM 2 Range interface. MSIE 6 does not
      support DOM 2 Range at all but has its proprietary DOM.
      - In my own testpage, DOM 2 CharacterData attributes and methods are
      impeccably, perfectly supported by MSIE 6 for Windows, Mozilla 1.x,
      Netscape 7.x, Safari 1.x, Konqueror 3.x, Opera 7.x, K-meleon 0.7+,
      Galeon 1.2+, etc.. So, it's worth to use these instead of proprietary
      attributes and methods.
      - MSIE 6 does not support DOM 2 CSS; Mozilla 1.x and Gecko-based
      browsers support very well most of the attributes and methods. Opera 7.x
      does not support DOM 2 CSS very well.

      This page:

      Browser Feature Detection


      shows a rough overview of the support for attributes and methods. When
      going over each attribute and method, one can find partial support,
      bugs, incomplete support, failures at tests, etc.. The measurement of
      support for an attribute and method depends in most part on how strict,
      exhaustive testing is done on each attribute and method.

      The W3C also created pages where one can tests exhaustively the support
      for attributes and properties:

      DOM Conformance Test Suites


      Finally Mozilla 1.6+ supports a few DOM 3 methods and attributes which
      were introduced in DOM 3. Since most DOM 2 attributes and methods are
      repeated in DOM 3, you could say Mozilla supports DOM 3 too.

      What does each DOM Level bring?
      The MDN Web Docs site provides information about Open Web technologies including HTML, CSS, and APIs for both Web sites and progressive web apps.


      DU

      Comment

      • Dr John Stockton

        #4
        Re: DOM: which version is most supported?

        JRS: In article <4113fa23$0$295 $ba620e4c@news. skynet.be>, dated Fri, 6
        Aug 2004 23:37:32, seen in news:comp.lang. javascript, Robert
        <nospam@yahoo.c om> posted :
        [color=blue]
        >which DOM version (level) should I learn? I've seen that there is a DOM
        >level 3, but is there any support for it already?[/color]

        On the Web, because of upwards compatibility, you should write in the
        lowest level of DOM that is needed to satisfy the site requirements;
        this will maximise your potential audience.

        You should also test on earlier browsers than those that you support
        fully, to ensure that the site degrades gracefully.


        In an Intranet for which you can know what and where the lowest-level
        browsers are, then write for the DOM of the lowest browsers that will
        need to access the pages.

        --
        © John Stockton, Surrey, UK. ?@merlyn.demon. co.uk Turnpike v4.00 IE 4 ©
        <URL:http://jibbering.com/faq/> JL / RC : FAQ for news:comp.lang. javascript
        <URL:http://www.merlyn.demo n.co.uk/js-index.htm> jscr maths, dates, sources.
        <URL:http://www.merlyn.demo n.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.

        Comment

        • Robert

          #5
          Re: DOM: which version is most supported?

          OK thanks Keith, DU and John, it helps me.
          --
          Rob

          Comment

          Working...