Re: [WSG] All in the Head: Document Type Definition
Lynne, on Tuesday, January 10, 2006 at 04:19 wsg@webstandardsgroup.org wrote: > On 1/10/06, Martin Heiden <[EMAIL PROTECTED]> wrote: >> Document Type Definitions were AFAIK first used by SGML and later >> for defining XML and XHTML. Because of the limitations of the DTD >> Language XML Schema has been developed. XML Schema is kind of >> heavyweight so that many people use the simpler RELAX NG instead. > XML is a subset of SGML - right? MMMmhhh I'm not sure about that one. But I hope this may clarify it: "So XML Is Just Like SGML? No. Well, yes, sort of. XML is defined as an application profile of SGML. SGML is the Standard Generalized Markup Language defined by ISO 8879. SGML has been the standard, vendor-independent way to maintain repositories of structured documentation for more than a decade, but it is not well suited to serving documents over the web (for a number of technical reasons beyond the scope of this article). Defining XML as an application profile of SGML means that any fully conformant SGML system will be able to read XML documents. However, using and understanding XML documents does not require a system that is capable of understanding the full generality of SGML. XML is, roughly speaking, a restricted form of SGML. For technical purists, it's important to note that there may also be subtle differences between documents as understood by XML systems and those same documents as understood by SGML systems. In particular, treatment of white space immediately adjacent to tags may be different." [1] I'm not sure if the term "subset" is specific enough. I'd say that XML is a SGML application profile. But probably you're right 'cause even the XML specification states that in the non normative part.[2] > But DTD's define the elements. attributes and entities of the document > type, and their order, and just happen to use SGML to do so. SGML not > XML - or am I missing something? AFAIK DTDs are neither specified in XML nor SGML but in a grammar which has been defined in the SGML and in a more restrictive way in the XML specification. The grammar defined in the XML specification is compatible with the SGML one. I didn't find a reference on what language is used for that grammar, but it goes back to the research of Noam Chomsky about formal languages and formal grammar.[3] With this DTD language/grammar you can only specify a XML document to the point of well-formedness. You can't say if an attributes value is valid or not. At this stage XML Schema comes in: XML Schema provides "a means for defining the structure, content and semantics of XML documents"[4] I hope this is understandable. regards Martin [1]http://www.xml.com/pub/a/98/10/guide0.html?page=2#AEN72 [2]http://www.w3.org/TR/2004/REC-xml-20040204/#sec-xml-and-sgml [3]http://en.wikipedia.org/wiki/Formal_grammar [4]http://www.w3.org/XML/Schema ** The discussion list for http://webstandardsgroup.org/ See http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting to the list & getting help **
Re: [WSG] All in the Head: Document Type Definition
On 1/10/06, Martin Heiden <[EMAIL PROTECTED]> wrote: > Document Type Definitions were AFAIK first used by SGML and later > for defining XML and XHTML. Because of the limitations of the DTD > Language XML Schema has been developed. XML Schema is kind of > heavyweight so that many people use the simpler RELAX NG instead. > Now I am getting confused! LOL XML is a subset of SGML - right? But DTD's define the elements. attributes and entities of the document type, and their order, and just happen to use SGML to do so. SGML not XML - or am I missing something? Lynne ** The discussion list for http://webstandardsgroup.org/ See http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting to the list & getting help **
Re: [WSG] All in the Head: Document Type Definition
Christian, on Monday, January 9, 2006 at 16:29 wsg@webstandardsgroup.org wrote: > "A Document Type Definition is an XML schema language and defines a > set of declarations that conform to a particular markup syntax." > Is this true for HTML DTD's? Are they XML as well? IMHO it's not wrong, but very confusing. A DTD defines a sort of schema, but DTDs aren't XML. They do the same, what can be achieved with XML Schema, but in a different way. Document Type Definitions were AFAIK first used by SGML and later for defining XML and XHTML. Because of the limitations of the DTD Language XML Schema has been developed. XML Schema is kind of heavyweight so that many people use the simpler RELAX NG instead. I think that Karl took that explanation from Wikipedia... regards Martin ** The discussion list for http://webstandardsgroup.org/ See http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting to the list & getting help **
Re: [WSG] All in the Head: Document Type Definition
On 1/9/06, Karl Dawson <[EMAIL PROTECTED]> wrote: > "All in the Head" is a series of articles that I am publishing to concisely > explain how and why to construct a high quality, web-standards compliant > head section for a web page. The first article examines the Document Type > Definition (DTD). > > http://www.thatstandardsguy.co.uk/2006/01/09/all-in-the-head-document-type-definitions/ > > Comments, especially error-spotting and general "bravo" very welcome, it all > helps with my work position. "A Document Type Definition is an XML schema language and defines a set of declarations that conform to a particular markup syntax." Is this true for HTML DTD's? Are they XML as well? -- -- Christian Montoya christianmontoya.com ... rdpdesign.com ... cssliquid.com ** The discussion list for http://webstandardsgroup.org/ See http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting to the list & getting help **
[WSG] All in the Head: Document Type Definition
Dear All,Apologies if this is wanton self-promotion, let me know so I don't spam again next week ;-)"All in the Head" is a series of articles that I am publishing to concisely explain how and why to construct a high quality, web-standards compliant head section for a web page. The first article examines the Document Type Definition (DTD).http://www.thatstandardsguy.co.uk/2006/01/09/all-in-the-head-document-type-definitions/Comments, especially error-spotting and general "bravo" very welcome, it all helps with my work position. Regards,-- Karl DawsonCrusader for Web Standards and Accessibilityhttp://www.thatstandardsguy.co.uk-- Accessites Team Member - http://www.accessites.org/--"The power of the Web is in its universality. Access by everyone regardless of disability is an essential aspect." Tim Berners-Lee - W3C Director and inventor of the World Wide Web