Re: Conceptual modelling of attributes

On 11 Jun 2007, at 16:04, Henri Sivonen wrote:

>  * An attribute may be present or not present.
>  * If it is present, it is a string triple: namespace, local name  
> and value. For most attributes, the namespace has a marker value  
> that signifies no namespace.
>  * The HTML-specific DOM properties that reflect attributes behave  
> as required by legacy and may not have a clean conceptual model.

OK. Then I take it that for ordinary element attributes that are  
accessed through the getAttribute and setAttribute functions:

getAttribute must return null if the attribute is not present.

getAttribute must the same value that has ben set with setAttribute.

Two more questions:

The spec says: "The contenteditable attribute is a common attribute.  
User agents must support this attribute on all HTML elements."

Does this mean that it is an ordinary element attribute or may it an  
attribute reflected by a HTML-specific DOM property?

Does anyone have examples of HTML specific DOM properties that  
reflect attributes?


Received on Monday, 11 June 2007 15:21:16 UTC