Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

compile time error in jstl tags

 
naresh govindaswmay
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
i have got the following error in time requesting the jsp file.
type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/core cannot be resolved in either web.xml or the jar files deployed with this application
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:50)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:411)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:118)
org.apache.jasper.compiler.TagLibraryInfoImpl.generateTLDLocation(TagLibraryInfoImpl.java:316)
org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java:147)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:418)
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)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
JstlServlet.doGet(Unknown Source)
javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75)

note The full stack trace of the root cause is available in the Apache Tomcat/5.0.28 logs.
Apache Tomcat/5.0.28
..........................................................................
what i did this file,using the jstl iterate all the values in this jsp file.i have included in uri in web.xml file also.pls give the solution for this problem i am looking for this one

this is the code for jsp file...
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
String[] Names=(String[])request.getAttribute("Names");
%>
<html>
<body>
This is the Attribute values...
<c:forEach var="name" items="${Names}">
${name}
</c:forEach>
</body>
</html>
 
Dave Seligson
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you moved the 2 core jstl (jstl.jar and standard.jar) libraries into the ../tomcat/webapps/[yourapp]/WEB-INF/lib folder? You can find these 2 libs in any of the sample webapps that Tomcat pre-installs.
 
naresh govindaswmay
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
I am using JBOSS and weblogic as a application servers...as of now i am not haveing the two jars. where i can get these jars..
 
Dave Seligson
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not sure where they belong in WebLogic, but using WebLogic 10.0, the 2 libraries can be found in several sample folders. Here's one:
C:\bea\wlserver_10.0\samples\server\examples\src\examples\webapp\jsp\tags\taghandler

If you are using the HeadFirst JSP & Servlets book, I would suggest you download Tomcat and follow the step-by-step with that. (Tomcat is free and there are instructions at the beginning of the book) It will make
your learning experience much more efficient.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
where i can get these jars..

Refer to this FAQ for the complete setup and links to both JAR files.
 
Daniel Jabonete
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you connected to the internet when you run the program?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you connected to the internet when you run the program?

Don't need to. The uri is just an internal mapping.
 
Amol Nayak
Ranch Hand
Posts: 218
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The uri is just a name framed as a url, its there under the uri tag in a tld file.
Another detail, you should either define <taglib> in your web.xml or make sure app is servlet 2.4 compatible.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic