Re: New draft: css3-selectors

fantasai wrote:

> Re: 6.4.3 Default attribute values in DTDs
> 
> I can conclude from the example that either
>   a) There is no mechanism for matching implicit attribute values
>      and the example just illustrates a workaround.
> or
>   b) The element selector, without an explicit attribute selector,
>      matches only elements that have all attributes implicitly
>      set to their default values. (Which is absurd.)
> 
> Moreover, the example seems to contradict the third sentence ("W3C
> selectors should be implemented so that they work even if the default
> values are not included in the document tree."), which to me implies
> that a selector "form[method=get]" will match
> <form action="script.cgi">
> 
> Am I reading this correctly? It's very confusing.

I'll start from the very beginning so all readers will follow.
An attribute which is not present explicitly in the markup but has a
default value assigned by its definition in the DTD is called
"implicit". An implicit attribute is _always_ there, even if not visible
in the markup and there is actually no way in *ML languages to force
the removal of such an attribute. Then selecting the element alone,
with no other extra condition on the attribute itself, is enough to
select the element with its default attribute value ser by DTD.

Is that clearer ?

</Daniel>

Received on Friday, 2 March 2001 16:26:43 UTC