?
Solved

Can <x:parse be non validating ?

Posted on 2004-04-01
2
Medium Priority
?
311 Views
Last Modified: 2010-05-18
I am extracting XML from a dbase and using jstl xml tag library to parse and display the xml.  The problem I have is that the XML contains a DOCTYPE with a relative DTD declaration eg.

<!DOCTYPE CustomerLoopService SYSTEM "CustomerLoopService.dtd">

As I do not have the DTD and no one knows where it is I get the following error when parsing.

java.io.FileNotFoundException: Could not resolve entity reference: "CustomerLoopService.dtd"
      at weblogic.xml.jaxp.ChainingEntityResolver.resolveEntity(ChainingEntityResolver.java:87)
      at weblogic.apache.xerces.readers.DefaultEntityHandler.startReadingFromExternalEntity(DefaultEntityHandler.java:768)
      at weblogic.apache.xerces.readers.DefaultEntityHandler.startReadingFromExternalSubset(DefaultEntityHandler.java:583)
      at weblogic.apache.xerces.framework.XMLDTDScanner.scanDoctypeDecl(XMLDTDScanner.java:1161)
      at weblogic.apache.xerces.framework.XMLDocumentScanner.scanDoctypeDecl(XMLDocumentScanner.java:2189)
      at weblogic.apache.xerces.framework.XMLDocumentScanner.access$0(XMLDocumentScanner.java:2143)
      at weblogic.apache.xerces.framework.XMLDocumentScanner$PrologDispatcher.dispatch(XMLDocumentScanner.java:856)
      at weblogic.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.java:399)
      at weblogic.apache.xerces.framework.XMLParser.parse(XMLParser.java:1147)
      at weblogic.apache.xerces.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:203)
      at weblogic.xml.jaxp.RegistryDocumentBuilder.parse(RegistryDocumentBuilder.java:144)

What I want to know is rather than stripping out the line

<!DOCTYPE CustomerLoopService SYSTEM "CustomerLoopService.dtd">

Can I specify to the <x:parse tag that I want it to be non validating and as a result ignore the DTD declaration ?

Thanks
0
Comment
Question by:crazyman
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 6

Expert Comment

by:jarasa
ID: 10731170
I guess not but maybe you can generate the dtd from the XML if you have a good one.

Javier
0
 
LVL 6

Accepted Solution

by:
jarasa earned 1000 total points
ID: 10731196
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you’re involved with your company’s wide area network (WAN), you’ve probably heard about SD-WANs. They’re the “boy wonder” of networking, ostensibly allowing companies to replace expensive MPLS lines with low-cost Internet access. But, are they …
Whoever said that “a picture is worth one thousand words” observed a fact that can dramatically affect your marketing success. Most people tend to learn visually, so many publishers commonly acknowledge the effectiveness of visual learning by using…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question