aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes JSLT problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "JSLT problem" Watch "JSLT problem" New topic
Author

JSLT problem

Raju Sri
Ranch Hand

Joined: Mar 10, 2004
Posts: 108
Hi ,

I am testing JSLT and JSP2.0 using Tomcat 5.0.24 version for SCWCD 1.4. I am facing one problem in JSLT . Below is my JSP page.
********************************
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>

<h3>Iterating over a range</h3>
<c:forEach var="item" begin="1" end="10">
<c ut value="${item}" escapeXml="true"/>
</c:forEach>

<br>
<%--
<c:forTokens items="moe,larry,curly" delimiters="," var="stooge">
<c ut value="${stooge}/><p>
</c:forTokens>
--%>

<c:url value="http://acme.com/exec/register" var="myUrl">
<c aram name="name" value="${param.name}"/>
<c aram name="country" value="${param.country}"/>
</c:url>
<a href='<c ut value="${myUrl}"/>'>Register</a>

********************************
I can able to test all core taglibs except "c:forTokens" . Tha's why I commented the code. The rest of the core tags are working fine.When I uncomment "c:forTokens" then I am getting below error

org.apache.jasper.JasperException: /jslt-coretags.jsp(48,19) The attribute prefix http does not correspond to any imported tag library
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:357)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:125)
org.apache.jasper.compiler.Parser.parseAttribute(Parser.java:185)
org.apache.jasper.compiler.Parser.parseAttributes(Parser.java:143)
org.apache.jasper.compiler.Parser.parseCustomTag(Parser.java:1328)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1560)
org.apache.jasper.compiler.Parser.parseBody(Parser.java:1789)
org.apache.jasper.compiler.Parser.parseOptionalBody(Parser.java:1060)
org.apache.jasper.compiler.Parser.parseCustomTag(Parser.java:1367)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1560)
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:439)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:422)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:507)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:274)
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)


Can somebody pls help me how to resolve this problem.

Regards
Raju


SCJP 1.4<br />SCWCD 1.4<br />SCBCD 1.3<br />SCDJWS 1.4
Atanas Roussev
Ranch Hand

Joined: Apr 07, 2004
Posts: 33
Hi Raju,

You are using wrong syntaxis. Proper one will look like:




Greetings
atanas
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: JSLT problem