This is the mail archive of the docbook@lists.oasis-open.org mailing list for the DocBook project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Any suggestions for a GOOD XML reference?


I'm no DTD expert but I think maybe what you are missing is some basic XML terminology. I'll tell you what I think the following means and try to show you how to understand in general the DTD.

Jeff Biss wrote:
I am learning XML while using the docbook DTD and really need a good reference. For example, I have "DocBook: The Definitive Guide" and "XML Bible" that do not provide information about the following DTD constructs:

<!ENTITY % local.list.class "">

When I go through the various modules in the docbook DTD I cannot figure out where "class" comes from or what "local.list.class" actually means.
The meaning of 'class' is a grouping. 'list.class' means the group of elements that are lists. the ENTITY syntax means that used here means that the 2nd argument (local.list.class) with a preceding '%' and a following ';' should be replaced where it occurs in the DTD with the 3rd argument ("", an empty string).

The line following the one you provided in the DTD is:

<!ENTITY % list.class
"calloutlist|glosslist|itemizedlist|orderedlist|segmentedlist
|simplelist|variablelist %local.list.class;">

This entity means that '%list.class;' should be replaced with the string that follows. Notice this string includes '%local.list.class';, which would be replaced with the entity you mentioned. So the point of 'local.list.class' is for customization. If you wanted to add elements to 'list.class' then you can just add them to 'local.list.class' in a customization layer and not worry about copying all the other elements already in 'list.class'. 'local' here stand for 'local customization'.

Can someone please provide what they consider a good reference that explains what is going on in the docbook (XML programming in general)?
http://xml.coverpages.org/xmlIntro.html contains a number of links to intro XML documents, but it seems you are more interested in DTDs. I suggest a google search for "DTD Tutorial" (in quotes)

Although it can be quite dry I would recommend eventually reading the XML spec at http://www.w3.org/TR/REC-xml. It also fully describes DTDs for XML, which makes it a handy reference.

--
Devin Bayer - http://elektrono.com/contact
I have never let my schooling interfere with my education.
-- Mark Twain


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]