- From: Masayasu Ishikawa <mimasa@w3.org>
- Date: Wed, 04 Sep 2002 15:04:08 +0900 (JST)
- To: Masahide Kanzaki <post@kanzaki.com>
- Cc: www-html-editor@w3.org, w3c-html-wg@w3.org
Hello, Thanks for your quick feedback. This reply is my personal opinion, not representing the opinion of the Working Group as a whole. Masahide Kanzaki <post@kanzaki.com> wrote: > I wonder if the legend element in fieldset should be optional > (minOccurs=0). Making it mandatory was very much intentional. > Obviously, the content model of fieldset in XHTML 1.0 DTD > defines it be optional, as shown: > > (#PCDATA | legend | %block; | form | %inline; | %misc;)* > > This model is different from that of HTML4 where legend is required. Also, > the comment in the DTD as well as the documentation in XML schema says: > > > Only one legend element should occur in the content > > and if present should only be preceded by whitespace. That comment was directly copied from DTD. As you noted, XML Schema version also notes: NOTE: this content model is different from the XHTML 1.0 DTD, closer to the intended content model in HTML4 DTD > Since there is a phrase "if present", it seems quite clear that legend > element is made optional intentionally, rather than just because of the > incapability of DTD mechanism. No, that's reversing canse and effect. We had to make it optional because of the incapability of DTD mechanism. > Although the editor notes "this content model is different from the XHTML > 1.0 DTD", this change makes many valid documents (in terms of DTD) invalid > against this schema, which is definitely unacceptable. The major purpose of providing XML Schemas in addition to DTDs is to allow better validation than DTD. Many "DTD-valid" documents which don't use correct data types will become Schema-invalid as well. This document explicitly states that these Schemas are "informative", and this document does not change the normative definition of XHTML 1.0. So long as your document meets all the criteria for strictly conforming XHTML 1.0 document, your document is syntactically a strictly conforming XHTML 1.0 document, whether it's Schema-valid or not. These XML Schemas provide additional checks to create "more-than-DTD-valid" XHTML 1.0 documents, which would be more likely to meet the constraints of the specification. You may be interested in the following thread on the www-html list: Subject: FIELDSET, LEGEND, HTML, & XHTML http://lists.w3.org/Archives/Public/www-html/2002Feb/thread#25 I said in that thread: So the semantics hasn't changed, but the XHTML 1.0 DTDs cannot enforce this restriction due to the limitation of XML 1.0. XML Schema could cope with this problem better, though. > I respect the introduction of order constraint (xs:sequence) in this > content model, which is well in accordance with DTD comment. Please > reconsider the minOccurs of the legend element. Personally I'm very reluctant to loosen this constraint for the sake of compatibility with the DTD incapability. Making legend optional is very bad for accessibility, and we would not have done so in XHTML 1.0 if XML DTD had enough capability to express that constraint. Regards, -- Masayasu Ishikawa / mimasa@w3.org W3C - World Wide Web Consortium
Received on Wednesday, 4 September 2002 02:04:11 UTC