Re: createElement

Default attributes are attribute values specified in the DTD, which will
appear on the element unless the user explicitly specifies another value
for those attributes.  For example, according to the XHTML and HTML4 DTDs,
the <button> element's type attribute has the default value "submit". If
you just write
     <button>
in your document, the resulting Element Node should automatically be given
an Attr with the name "type", the value "submit", and the unspecified flag
set to true.

If the DTD doesn't specify a default value for the Attr, there isn't a
default Attr node.

If you don't have a DTD to consult (eg, if you used a nonvalidating XML
parser and your document's internal subset doesn't specify a default for
this attribute), there isn't a default Attr node.

______________________________________
Joe Kesselman  / IBM Research

Received on Thursday, 5 October 2000 11:32:40 UTC