This is very useful information, and I thank you for it.

I found the DOM spec you referred to.  I guess now I am trying to find out what DOM 
implementation does support id().
I tried using the org.apache.xerces.parsers.DOMParser's getDocument() method which 
uses the org.w3c.dom, but a call
to the document.getElementById() always returns null.

Does anyone know of a DOM / DOMParser that does work with getElementById()?
What does the org.apache.xalan.xslt.XSLTInputSource use?  Can I use that?
-- Daniel Einspanjer, [EMAIL PROTECTED] on 07/13/2001


On Thu, 12 Jul 2001 16:18:08 -0400, [EMAIL PROTECTED] wrote:
>
>If you're using a DOM as input, support for the id() function is dependent
>upon the DOM's getElementByID() function. So the real question here is why
>your DOM isn't providing that information.
>
>Quoting the DOM spec:
>���Note: The DOM implementation must have information that says which
>attributes are
>����������of type ID. Attributes with the name "ID" are not of
>type ID unless so defined.
>����������Implementations that do not know whether attributes are
>of type ID or not are
>����������expected to return null.
>
>The individual DOM implementation has to decide when this information is
>available and how it's maintained. In most current DOMs, you don't "know
>whether attributes are of type ID" unless the DOM was validated against a
>DTD or schema that provides this information. In many DOMs, that
>information is set only by a validating parser, and attributes added after
>that may not be checked to see whether they should be added to the ID list.
>
>DOM Level 3's "abstract schema" chapter, now under development, will
>provide better support for DTDs/schemas generally and for IDs in specific,
>in those DOMs which implement that feature. Until then, and in DOMs which
>choose not to support those APIs, you're stuck with "it works when the DOM
>implementation says it works."
>
>If you think your DOM implementation _should_ be supplying this
>information, and it doesn't, report that to its support team.
>
>


Reply via email to