OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Subject: Re: DOCBOOK: Question regarding DocBook for SGML and XML

"Noble, Benjamin, ALEAT" <noble1@att.com> writes:

> From my understanding, the DocBook DTD for SGML defines the same set
> of elements and structure as the DocBook DTD for XML; only one is for
> SGML and the other for XML. Is this correct?

It defines the same elements, and mostly the same content models for
those elements, with the biggest difference being that the SGML DTD
contains SGML exclusions in some content models -- for example, the
SGML DTD excludes <footnote> as a descendent of <footnote>, because it
doesn't make much practical sense to have footnotes within footnotes.

XML DTDs can't contain exclusions, so if you're authoring using the
DocBook XML DTD, it's possible to produce documents containing some
valid-but-not-logical markup like footnotes within footnotes.

Appendix B.1 of "DocBook: The Definitive Guide" has details about some
other differences.


> Moreover, if I create a DocBook SGML document, how close is it to a
> DocBook XML document? I imagine that, with some
> modifications/limitations to the SGML document, I'll have a DocBook
> XML document (just need to change the DOCTYPE).

For that, take a look at Appendix B.2, "DocBook Instances as XML":


You should be able to run James Clark's "sx" utility on your SGML doc
instances to convert them to XML.


You might also need to run his "sgmlnorm" on them first.


Hey DaveP, this is probably a good one for the FAQ.


Michael Smith                          smith@xml-doc.org            
17F Shinjuku Square Tower Bldg         +81 90 6175 6931 (mobile)    
6-22-1 Nishishinjuku                   +81  3 5909 6347 (office)    
Shinjuku-ku, Tokyo, Japan 163-1129     +81  3 5909 6241 (fax)

DocBook Technical Committee member     xmlhack contributing editor  
http://www.oasis-open.org/docbook/     http://xmlhack.com/          
DocBook Open Repository member         xml-doc mailing list moderator 
http://docbook-sourceforge.net/        http://xml-doc.org/          
Logopoeia Web knob twister             http://www.logopoeia.com/

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Powered by eList eXpress LLC