| Author |
Error Loading jsp file - Unable to initialize TldLocationsCache: null
|
chaity mk
Greenhorn
Joined: Mar 29, 2006
Posts: 2
|
|
I am getting this error when i am loading JSP file. Error: org.apache.jasper.JasperException: Unable to initialize TldLocationsCache: null org.apache.jasper.compiler.TldLocationsCache.init(TldLocationsCache.java:249) org.apache.jasper.compiler.TldLocationsCache.getLocation(TldLocationsCache.java:220) org.apache.jasper.JspCompilationContext.getTldLocation(JspCompilationContext.java:475) org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:417) org.apache.jasper.compiler.Parser.parseDirective(Parser.java:483) org.apache.jasper.compiler.Parser.parseElements(Parser.java:1539) org.apache.jasper.compiler.Parser.parse(Parser.java:126) org.apache.jasper.compiler.ParserController.doParse(ParserController.java:220) org.apache.jasper.compiler.ParserController.parse(ParserController.java:101) org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:203) org.apache.jasper.compiler.Compiler.compile(Compiler.java:470) org.apache.jasper.compiler.Compiler.compile(Compiler.java:451) org.apache.jasper.compiler.Compiler.compile(Compiler.java:439) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:295) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292) JSP Program ----------- <%@ page import="java.util.*" language="java" session="true" autoFlush="true" %> <%@page contentType="text/html"%> <!-- <%@ taglib uri="struts-logic.tld" prefix="logic" %> <%@ taglib uri="struts-bean.tld" prefix="bean" %> <%@ taglib uri="struts-html.tld" prefix="html" %> --> <HTML><!-- #BeginTemplate "/Templates/CBSTemplate.dwt" --> <HEAD> <!-- #BeginEditable "doctitle" --> <meta http-equiv="Pragma" content="no-cache"> <meta http-equiv="Expires" content="Mon, 01 Jan 1990 12:00:00 GMT"> <meta http-equiv="Cache-control" content="no-cache"> <meta http-equiv="Cache-control" content="must-revalidate"> <meta http-equiv="Cache-control" content="max-age=0"> <LINK href="Style/Style.css" rel=stylesheet> <STYLE type="text/css"> A.DDJ:link { TEXT-DECORATION: none } A:hover{color:black} A{text-decoration:none} </STYLE> </HEAD> . . . . .
|
 |
Liju Cherian
Ranch Hand
Joined: Mar 17, 2006
Posts: 44
|
|
Hi, Where are your .tld files located ..?? and could u plz post your taglib directive from the web.xml file.
|
"What's in a name? That which we call a rose by any other name would smell just as sweet."<br />(William Shakespeare, Romeo and Juliet, Act II, Scene II)
|
 |
chaity mk
Greenhorn
Joined: Mar 29, 2006
Posts: 2
|
|
i have solved that by commenting the tld tag related in web.xml and i am directly referring the tld location...as follows <%@ taglib uri="/Tags/struts-logic.tld" prefix="logic" %> <%@ taglib uri="/Tags/struts-bean.tld" prefix="bean" %> <%@ taglib uri="/Tags/struts-html.tld" prefix="html" %> i am also getting one more error as follows: javax.servlet.ServletException: No collection found org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:825) org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:758) org.apache.jsp.NewsDetailsDDJ_jsp._jspService(NewsDetailsDDJ_jsp.java:257) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) i am trying the ws-struts example from IBM site.... <logic:iterate id="newsListID" name="newsForm" property="newsDetails" scope="request"> <p><b><font color='blue'> <bean:write name="newsListID" property="newsContent"/> </font> </b> </p> </logic:iterate> the above is the code snippet raising the error please let me know the soln. thanx in advance
|
 |
Liju Cherian
Ranch Hand
Joined: Mar 17, 2006
Posts: 44
|
|
Hi again, Well, good to know u've resolved the first issue. Now about the 2nd issue. In the logic:iterate tag you've specified a newsDetails collection of request scope. the error points out that such a collection is not available in the defined scope. Try checking the servlet and see if u've actually set the collection to request before forwarding to the jsp; or then again it could be a simple spelling mistake. Hope this helps. Liju
|
 |
 |
|
|
subject: Error Loading jsp file - Unable to initialize TldLocationsCache: null
|
|
|