[Home] [By Thread] [By Date] [Recent Entries]

  • From: John-Paul Sicotte <John-Paul@m...>
  • To: xml-dev@l...
  • Date: Tue, 17 Apr 2001 17:12:04 -0600


Hi,

   I have recently been playing around with entities using expat 1.2 
and have come across what appears to be a contradiction in the XML 
recommendation.


The entities are from an example in section 4.5 of the XML rec and our 
as follows.

<!ENTITYÊ%ÊpubÊÊÊÊ"&#xc9;ditionsÊGallimard"Ê>
<!ENTITYÊÊÊrightsÊ"AllÊrightsÊreserved"Ê>
<!ENTITYÊÊÊbookÊÊÊ"LaÊPeste:ÊAlbertÊCamus,Ê
&#xA9;Ê1947Ê%pub;.Ê&rights;"Ê>

This example along with the 2nd paragraph of section 4.5 seem to make 
it clear that parameter entities are usable inside and internal entity 
definition and that they should be expanded to get the entity's 
replacement text.


This appears to contradict the paragraph starting:
"Well-Formedness Constraint: PEs in Internal Subset" in section 2.8 of 
the recommendation.  IE 5 for mac seems to agree with section 2.8 and 
complains if the following file is loaded.  

---------------------
<?xml version = "1.0"?>

<!DOCTYPE document [

<!ENTITY % pub    "&#xc9;ditions Gallimard">
<!ENTITY   rights "All rights reserved">
<!ENTITY   book   "La Peste: Albert Camus,
&#xA9; 1947 %pub;. &rights;">

]>

<document>
&book;
</document>
--------------------------------


Am I missing something subtle here?  The grammer appears to agree with 
section 2.8 and I would lean towards it over the text if the two 
disagreed but it seems to be quite clear in section 4.5 that the above 
xml file is legal.

								
John-Paul
----------------------
John-Paul Sicotte
Software Composer
MessagingDirect
mailto:John-Paul@M...



Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member