File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes XML in a JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "XML in a JSP" Watch "XML in a JSP" New topic

XML in a JSP

Tom Diamond
Ranch Hand

Joined: May 10, 2001
Posts: 98
Hello people,
When I am trying to read from an XML file inside a JSP page I get a ParserConfigurationException. What may have caused that? (The code itself has been tested as an app and it's OK).
William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 13025
ParserConfigurationException gets thrown when there is a serious error involving the parser classes. Perhaps you have conflict between different parser versions? Which parser are you trying to use?
Tom Diamond
Ranch Hand

Joined: May 10, 2001
Posts: 98
Actually, I don't know :-)
I have a Jakarta-Tomcat server (ver. 4 - beta 5) and the first time I tried my page I got the configuration exception. Then I put a couple of jars in Root/WEB-INF/lib directory (jaxp.jar, crimson.jar, xalan.jar - think they are the Sun's API for XML parsing) and the problem got bigger : the server shutdown on its own and I had to exlpore the logs to find out that a "NoClassDefFoundException : javax/xml/parsers/ParserConfigurationException not found" (or omething similar to that...) had occurred.
Any ideas???
I agree. Here's the link:
subject: XML in a JSP
It's not a secret anymore!