RE: 'entity' attribute, some questions

> For the entity attribute it is not clear absolutley clear to me what
> notationName  or systemID is meant to return.
> 
> if the XML document contains the entity reference &dom;
> 
> If the DTD contained the entity declaration:
> 
> <!ENTITY  dom  "Document Object Model">
> 
> would the method:
> 
> 	var x=dom.notationName
> 
> assign to the varible x  the string
> 
> 	"Document Object Model"
> 
> or the string 
> 
> 	"dom"

Neither. Notations are only used for unparsed entities.

> Similarly if the DTD contained the entity declaration:
> 
> <!ENTITY  dom  SYSTEM "XMLtutorial.txt">
> would the method:
> 
> var x=dom.systemID
> 
> 	 assign to the varible x  the string
> 
> 	"XMLtutorial.txt"
> 
> or would it assign the contents of the file XMLtutorial.

The string "XMLtutorial.txt".

Admittedly, the spec could always be better worded...

Received on Monday, 27 July 1998 01:01:43 UTC