954,574 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Accessing xml content in jsp through JSTL

Hi
I need to get values from xml file. I am trying to do this through JSTL.I worked out in following manner,

<%@   taglib  prefix="c" uri="http://java.sun.com/jstl/core" %> 
<%@   taglib  prefix="x" uri="http://java.sun.com/jstl/xml"   %> 
 <c:import   url="/corporate/commonjs/YUI_js/validation/valid.xml"    var="url" />  
 <x:parse xml="${url}"     var="doc"   /> 
 <x:out select="$doc/validationcheck/required"  />
My xml file contains,
<validationcheck>
	<required>Required</required>
	<required>この項目は必須です</required>
</validationcheck>
but it give me following error,
java.lang.NoClassDefFoundError: org/saxpath/SAXPathException
                   Then i adopt to download taglibs-xsl.jar file. First i copy taglibs-xsl.jar  to "jboss-4.0.3SP1\lib" folder then i extracted taglibs-xsl.tld from taglibs-xsl.jar and copied to WEB-INF.Finally i made mapping in web.xml as given below,
 <taglib>
    <taglib-uri>/WEB-INF/tablibs-xsl.tld</taglib-uri>
    <taglib-location>/WEB-INF/tablibs-xsl.tld</taglib-location>
  </taglib>


After making these configuration i got error saying no class found exception . pls help me for this solution

shareme
Newbie Poster
1 post since Dec 2008
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You