[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Parameter entities?

  • From: dvint@d...
  • To: xml-dev@l...
  • Date: Fri, 22 Aug 2008 11:54:24 -0400 (EDT)

Parameter entities?
I'm trying to convert a DTD that was originially designed for SGML, but we
now want to use it with XML. I have the following definition:

<!ENTITY % config          "configuration?" >

<!ENTITY % front.matter    "(cover, revision.record, toc, lof, lot,
acronym.list, safety.summary, references)" >

<!ENTITY % body.contents   "((chapter+ | appendix*) , %config;)+" >

Xerces complains about the use of the %config; entity reference in the
definition of  %body.contents. The error is:

[Fatal Error] cats.dtd:102:63: The parameter entity reference "%config;"
cannot occur within markup in the internal subset of the DTD.

but I can't validatiate this with the 1.1 spec and I don't think this area
changed from the earlier version. So we have:

[72]    PEDecl    ::=    '<!ENTITY' S '%' S Name S PEDef S? '>'
[74]    PEDef    ::=    EntityValue | ExternalID
[9]    EntityValue    ::=    '"' ([^%&"] | PEReference | Reference)* '"'
   |  "'" ([^%&'] | PEReference | Reference)* "'"
[69]    PEReference    ::=    '%' Name ';'


That sequence of rules seems to me to allow this:

"((chapter+ | appendix*) , %config;)+"

So maybe it doesn't allow the other content to be there witht the PE
reference. So I changed the model to this:

<!ENTITY % config          "(configuration)?" >
<!ENTITY % body.contents   "%config;" >

I still get the same error with this design. What am I missing?
..dan








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


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.