OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Referencing an external DTD

[ Lists Home | Date Index | Thread Index ]

hi,
I am facing problems while trying to parse an XML file, when the
correspoding DTD is a jar file resource. I get the following error

org.xml.sax.SAXException: Fatal Error:
URI=jar:file:/u/arun/projects/base/jar/c.jar!/config/prices/parser/input.xml
Line=2: External entity not found:
"jar:file:/u/arun/projects/base/jar/c.jar!/config/prices/parser/../gui/forma
t.dtd".
at deshaw.common.format.parser.XmlParser.fatalError(XmlParser.java:575)
at org.apache.crimson.parser.Parser2.fatal(Parser2.java:3185)
at .....

my xml file URI is 
jar:file:/u/arun/projects/base/jar/c.jar!/config/prices/parser/input.xml

the dtd is in the same jar "c.jar", albeit in a different directory "gui"
jar:file:/u/arun/projects/base/jar/c.jar!/config/prices/gui/format.dtd

in input.xml i am trying to reference the dtd as follows
<!DOCTYPE format SYSTEM "../gui/format.dtd">

however this relative reference does not work, and throws the above
exception. i can't understand why this fails. Can somebody throw more light
on this problem, and help me resolve it?
Thanks
arun

Things will be bright at 10 P.M.  A cop will shine a light in your face.





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS