W3C home > Mailing lists > Public > xml-editor@w3.org > July to September 2005

external entities

From: Junfeng Dong <junfengd@microsoft.com>
Date: Wed, 6 Jul 2005 22:30:11 -0700
Message-ID: <5D4C188603359E4DAD08F6ACF5FDA3A101A4F158@RED-MSG-52.redmond.corp.microsoft.com>
To: <xml-editor@w3.org>

Dear Sir or Madam,
I have a question for the definition of external entities. Suppose there is an xml document given as follow:
<!DOCTYPE root SYSTEM "ext.dtd" []><root a="&ext;"/>
The content of file ext.dtd is:
<!ENTITY ext "blah">
Is entity ext counted as an internal entity or an external entity? In xml specification, "The document type declaration can point to an external subset (a special kind of external entity) containing markup declarations," In my understanding, since ext.dtd is an external subset and a special kind of external entity, then ext is by default, an external entity. However, by the definition of internal entity ("If the entity definition is an EntityValue, the defined entity is called an internal entity. There is no separate physical storage object, and the content of the entity is given in the declaration."), entity ext is an internal entity. I am confused here. Since if ext is an external entity, then the document isn't well-formed.
Thanks in advance.
Received on Thursday, 7 July 2005 05:34:49 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:37:46 UTC