aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes JSTL Example Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "JSTL Example" Watch "JSTL Example" New topic
Author

JSTL Example

Nikhil Jain
Ranch Hand

Joined: May 15, 2005
Posts: 385
Hello ranchers,
I was just trying to use JSTL in my code. I wrote the following code from HFS. Prior to this I copied the jstl.jar to my web apps lib folder. But I get the following error.
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

Do I need to put something in web.xml?
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<body>
<table>
<c:forEach var="movie" items="${movieList}" >
<tr>
<td>${movie}</td>
</tr>
</c:forEach>
</table>
</body>
</html>


SCJP 1.4, SCWCD 1.4, SCBCD 1.5
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14688
    
  16

don't forget to put standard.jar also in your lib directory.


[My Blog]
All roads lead to JavaRanch
Nikhil Jain
Ranch Hand

Joined: May 15, 2005
Posts: 385
wow! that was quick answer, anyways, it worked. Thanks a lot. But the book did not mention anything about standard.jar. What is it for?

thanks once again,
shashank
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14688
    
  16

It's an implementation of JSTL.
 
jQuery in Action, 2nd edition
 
subject: JSTL Example