Errata

XML in a Nutshell

Errata for XML in a Nutshell

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released.

The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.

Color Key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted by Date submitted
5.4
1st paragraph

Section 5.4 starts with -

An XML parser is required to handle the UTF-16 and UTF-8 encodings or Unicode (about which more follows).

Should be 'of', not 'or',

An XML parser is required to handle the UTF-16 and UTF-8 encodings of Unicode (about which more follows).

Anonymous  Jul 30, 2008 
Printed Page 19
1st paragraph

The text states that "Only < and & must be used in place of the literal characters in element content." This is incorrect because the XML spec also requires the use of > in a literal sequence ]]> for SGML backwards compatibility.

See http://www.w3.org/TR/2000/REC-xml-20001006#syntax second paragraph, last sentence for the rule.

Anonymous   
Printed Page 21
4th paragraph

8/01 printing

XML, Xml, etc.) is resolved for use by the W3C

should be

XML, Xml, etc.) is reserved for use by the W3C

Anonymous   
Printed Page 22
Example 2-8

This is probably just a typo, but:

encoding="ISO-8859_1" should read encoding="ISO-8859-1"

Anonymous   
Printed Page 31
First paragraph after example 3-4

Book says "SYSTEM or PUBLIC URI". This is not true: while SYSTEM
identifiers are certainly URIs, PUBLIC ones are Formal Public Identifiers
(FPI) and they has nothing in commong with URIs.

Anonymous   
Printed Page 35
The number of Children

In the book:
x
? Permits zero or one of the element
* Permits zero or one of the element
+ Permits zero or one of the element

What it should say based on subsquent text in book:

? Permits zero or one of the element
* Permits zero or more of the element
+ Requires one or more of the element

Anonymous   
Printed Page 36
last paragraph

The text of the last paragraph reads: "Suppose you want to say that a circle
element contains a point element and either a radius or a diameter element,
but not both."

But the declaration example lists a circle element with a *center* element
instead of a *point* element like so:
<!ELEMENT circle (center, (radius | diameter))>
^^^^^^

Anonymous   
Printed Page 56
Last page of Chapter 3

Microsoft will be shutting down the BizTalk.org web site on July 19, 2002. Please do
not refer to the site.

Anonymous   
Printed Page 59
Example near end of page

Text Reads:
"<title>Impressionist Paintings</dc:title>"

Should be:
"<title>Impressionist Paintings</title>"

Anonymous   
Printed Page 71
in the list of encodings and in the last paragraph

January 2001 printing
p. 71

besides the already reported UF-16 error, there may be two more, both having to do
with an underscore character:

In the list of character encodings the last entry of the first column reads
Shift_JIS. Is this correct or should it be Shift-JIS (with a hyphen)?

In the middle of the paragraph right below that list:

"...both Latin-1 and 8859_1 are sometimes used ... "

Is it 8859_1 or should it be 8859-1 ?

Anonymous   
Printed Page 80
1st from bottom

provides complete charts showing of all characters in these entity sets.

"showing all characters"

Anonymous   
Printed Page 102-103
Example 7-2

January 2001 printing
pp. 102-103
Example 7-2

In Example 7-2 all the CSS properties which have a length value not equal to zero
lack unit identifiers (e.g. em, px, %, etc.). CSS requires them. Thus, in the book:

<hr style="height: 1 ... [error occurs twice]
...
<div style="font-size: 1 ...
...
<p style="font-size: 1 ...

Anonymous   
Printed Page 102
line 7 of Example 7-2

XML in a Nutshell
January 2001 printing

In line 7 of Example 7-2

body {backgroundColor: #FFFFFF; color: #000000}

backgroundColor is not a valid CSS property. This should be written as background-
color

Anonymous   
Printed Page 103
line 13

Example 7-2
p. 103
line 13

<div style="font-size: 1; font-face: Verdana, Arial, Helvetica; text-align: center">

There is no font-face CSS property (only an @font-face rule). This should be changed
to font-family.

Anonymous   
Printed Page 127
Example 7-10

XML in a Nutshell
January 2001 printing

In the last sentence of the second paragraph on page 61 the authors state that "RDF
barely avoids a collision with the Dublin Core over the Description and description
elements."

In Example 4-3 on page 63 all Dublin Core elements are properly written in lower
case. However, in Example 7-10 on page 127 the xml code reads:

<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dc="http://www.purl.org/dc/">

<rdf:Description about="urn:isbn:0596000588">
<dc:Title>XML in a Nutshell</dc:Title>
<dc:Creator>W. Scott Means</dc:Creator>
<dc:Creator>Elliotte Rusty Harold</dc:Creator>
<dc:Subject>XML (Document markup language)</dc:Subject>
<dc:Description>
A brief tutorial on and quick reference to XML and
related technologies and specifications
</dc:Description>
<dc:Publisher>O'Reilly & Associates</dc:Publisher>
<dc:Contributor>Laurie Petrycki</dc:Contributor>
<dc:Date>2001-01-23</dc:Date>
<dc:Type>text</dc:Type>
<dc:Format>6" x 9"</dc:Format>
<dc:Identifier>0596000588</dc:Identifier>
<dc:Language>en-US</dc:Language>
<dc:Relation>http://www.oreilly.com/catalog/9780596000585/</dc:Relation>
<dc:Coverage>US UK ZA CA AU NZ</dc:Coverage>
<dc:Rights>Copyright 2000 O'Reilly & Associates</dc:Rights>
<rdf:Description>

<rdf:RDF>

In this example all Dublin Core elements have been capitalized. In the XML/RDF
example in the Dublin Core User Guide
(http://uk.dublincore.org/documents/usageguide/) all DC elements are in lower case.
The above code should thus be rewritten as:

<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dc="http://www.purl.org/dc/">

<rdf:Description about="urn:isbn:0596000588">
<dc:title>XML in a Nutshell</dc:title>
<dc:creator>W. Scott Means</dc:creator>
<dc:creator>Elliotte Rusty Harold</dc:creator>
<dc:subject>XML (Document markup language)</dc:subject>
<dc:description>
A brief tutorial on and quick reference to XML and
related technologies and specifications
</dc:description>
<dc:publisher>O'Reilly & Associates</dc:publisher>
<dc:contributor>Laurie Petrycki</dc:contributor>
<dc:date>2001-01-23</dc:date>
<dc:type>text</dc:type>
<dc:format>6" x 9"</dc:format>
<dc:identifier>0596000588</dc:identifier>
<dc:language>en-US</dc:language>
<dc:relation>http://www.oreilly.com/catalog/9780596000585/</dc:relation>
<dc:coverage>US UK ZA CA AU NZ</dc:coverage>
<dc:rights>Copyright 2000 O'Reilly & Associates</dc:rights>
<rdf:Description>

<rdf:RDF>

Moreover, the DC namespace URI has been updated so the xmlns attribute should now
read:

xmlns:dc="http://purl.org/dc/elements/1.1/"

Anonymous   
Printed Page 133
1st para

typo:

original:
<?xml version="1.0"?>
<?xml-stylesheet type="text/x*m*l" href="http://www.oreilly.com/styles/people.xsl"?>
<people>
....

corrected:
<?xml version="1.0"?>
<?xml-stylesheet type="text/x*s*l" href="http://www.oreilly.com/styles/people.xsl"?>
<people>

Anonymous   
Printed Page 153
First line

First sentence should be read as "It outputs that element's name child
element value along with born and died attributes' values, ...".

Anonymous   
Printed Page 166
4th paragraph

the sample to extract the DD should read
substring('MM/DD/YYYY', 4, 2)
not
substring('MM/DD/YYYY', 2)

Anonymous   
Printed Page 189
Example for the range-inside() function contained in the "The

range-inside() Function" section;
The example given for the range-inside() section, mentioned above, has the
following:

pointer(range(//title))

Considering the discussion which follows this example, and the section in
which the example is found. I feel that the correct example would be:

xpointer(range-inside(//title))

Anonymous   
Printed Page 194
Figure 12-1

In the first paragraph of the recipe for Southern Corn Bread, it says to "Add melted shortening..." to the batter; however, the ingredients do not include shortening. Most likely the sentence should begin with "Add melted butter..." instead.

Also, the first sentence says to sift "...sugar & salt together." The ingredients do not seem to mention the quantity of sugar that is required.

Anonymous   
Printed Page 202
line 14

XML in a Nutshell
January 2001 printing
p. 202

in the CSS code:

dish (height: 0.5 cm}

There should be no whitespace between 1.5 and cm. It should read 1.5cm

Anonymous   
Printed Page 212
1st paragraph

The text states that the start and end regions are half an inch wide and the before
and after regions are an inch wide, but in the XML fragment all regions are half an
inch:

<fo:region-before extent="0.5in"/>
<fo:region-after extent="0.5in"/>
<fo:region-start extent="0.5in"/>
<fo:region-end extent="0.5in"/>

should it be:

<fo:region-before extent="1.0in"/>
<fo:region-after extent="1.0in"/>
<fo:region-start extent="0.5in"/>
<fo:region-end extent="0.5in"/>

To match the body margins?

Anonymous   
Printed Page 218
Example 13-4 Line 17 (counting blank lines)

The example was not working with FOP until I changed the following
From

<fo:page-sequence master-name="first">
<fo:flow>

To
<fo:page-sequence master-reference="first">
<fo:flow flow-name="xsl-region-body">

Anonymous   
Printed Page 229
First paragraph

"the XML parse wouldn't know" should be "the XML parser wouldn't know"

Anonymous   
Printed Page 236
Code example at bottom of page

"Node item(in unsigned long index)" should be "Node item(int unsigned long index)"

Anonymous   
Printed Page 237
first sentence

This interface would be expressed as a Java inteface like this:

"as a Java interface"

Anonymous   
Printed Page 281
Table 18-1

XML in a Nutshell
January 2001 printing

p. 281
Table 18-1

Entity Character XML Declaration
--------------------------------------------------
< < <!ENTITY lt "&#60;">
& & <!ENTITY amp "&#38;">
--------------------------------------------------

The entity declarations are erroneous. They should be:

<!ENTITY lt "<">
<!ENTITY amp "&">

Anonymous   
Printed Page 294
Last paragraph

"<empty_element></empty_element>" should be probably written as
"<empty_element [attribute_name="attribute_value"]*></empty_element>".

Anonymous   
Printed Page 295
Lower half, through to page 298

The EBNF grammar (including the one given in the corrections included in
the 3/01 reprint) is missing about twenty productions, including (no
guarantee that this list is complete or that individual items in it are
correct):

Name ::= (Letter | '_' | ':') (NameChar)*
Names ::= Name (S Name)*
Nmtoken ::= (NameChar)+
Nmtokens ::= Nmtoken (S Nmtoken)*

AttValue ::= '"' ([^<&"] | Reference)* '"' | "'" ([^<&'] | Reference)*
"'"[11] SystemLiteral ::= ('"' [^"]* '"') | ("'" [^']* "'")
PubidLiteral ::= '"' PubidChar* '"' | "'" (PubidChar - "'")* "'"
PubidChar ::= #x20 | #xD | #xA | [a-zA-Z0-9] | [-'()+,./:=?;!*#@$_%]

PITarget ::= Name - (('X' | 'x') ('M' | 'm') ('L' | 'l'))

CDStart ::= '<![CDATA['
CData ::= (Char* - (Char* ']]>' Char*))
CDEnd ::= ']]>'

EntityRef ::= '&' Name ';'
PEReference ::= '%' Name ';'

NDataDecl ::= S 'NDATA' S Name

EncName ::= [A-Za-z] ([A-Za-z0-9._] | '-')*

PublicID ::= 'PUBLIC' S PubidLiteral

Anonymous   
Printed Page 310
First bullet of number function, last sentence

According to W3, exponential notation is NOT recoginized.
(XALAN for C++ does not allow it)

Anonymous   
Printed Page 316
two bulleted sections, beginning at the top of page

The xsl:apply-imports element appears in both the top-level element list and the instruction element list. Also, the xsl;with-param element does not appear in either list. Please clarify.

Anonymous   
Printed Page 335
description of priority attribute

This description states that priority is "a number"
and that "the [template] with the highest priority is
chosen". It then goes on to describe how the numbers are
calculated. However, I could not find any explicit
reference as to whether a higher number means a higher
priority or vice versa. This may be implied, but it would
be helpful if it was actually stated somewhere in the
description.

Anonymous   
Printed Page 363
Result of importNode method for ELEMENT_NODE node type in the table

at the end of the page;
"Copies only the attribute with the specified flag set to the new element"
should be written as "Copies only the attribute with the ownerElement
attribute set to the new element."

Anonymous   
Printed Page 381
publicId description

Public IDs are not URLs or URIs, they're FPIs. So, neither method
description, nor example aren't correct. You can't find protocol of Puclic
ID, because they doesn't have protocols.

Anonymous   
Printed Page 438
Table 23-12: The Cyrillic Block of Unicode

There are a couple of rows missing.
The rows should follow the row numbered 428-42F.

Anonymous