tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Luc Margaron <luc.marga...@metrixsystems.com>
Subject Tomcat 3.1 tag problem
Date Thu, 25 May 2000 07:20:57 GMT
Hi,

I use Tomcat 3.1 and I cannot make the tag work

In my web.xml I have the entry

     <taglib>
        <taglib-uri>http://luc/taglib</taglib-uri>
        <taglib-location>
           /WEB-INF/tgld/taglib.tld
        </taglib-location>
    </taglib>

I have the tag classes in /WEB-INF/classes


my file taglib.tld is in /WEB-INF/tgld/taglib.tld


in  Hello.jsp I have :

<%@ taglib uri="http://luc/taglib" prefix="mt" %>
<HTML>
<BODY>
   <HEAD>
       <TITLE> Hello World! </TITLE>
   </HEAD>
       <HR>
           <mt:HelloWorld/>
       <HR>
   </BODY>
</HTML>


when I execute Hello.jsp I have the following error:

       Location: /goodies/jsp/HelloTag.jsp

Internal Servlet Error:

org.apache.jasper.JasperException: Unable to open taglibrary
http://luc/taglib : Parse Error in the tag library descriptor: Element
"web-app" does not allow "servlet" here.
        at
org.apache.jasper.compiler.JspParseEventListener.handleDirective(JspParseEventListener.java:672)

        at
org.apache.jasper.compiler.DelegatingListener.handleDirective(DelegatingListener.java:116)

        at
org.apache.jasper.compiler.Parser$Directive.accept(Parser.java:215)
        at org.apache.jasper.compiler.Parser.parse(Parser.java:1073)
        at org.apache.jasper.compiler.Parser.parse(Parser.java:1038)
        at org.apache.jasper.compiler.Parser.parse(Parser.java:1034)
        at
org.apache.jasper.compiler.Compiler.compile(Compiler.java:182)
        at
org.apache.jasper.runtime.JspServlet.loadJSP(JspServlet.java:413)
        at
org.apache.jasper.runtime.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:149)

        at
org.apache.jasper.runtime.JspServlet$JspServletWrapper.service(JspServlet.java:161)

        at
org.apache.jasper.runtime.JspServlet.serviceJspFile(JspServlet.java:261)

        at
org.apache.jasper.runtime.JspServlet.service(JspServlet.java:369)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at
org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java:503)

        at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:559)
        at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:160)

        at
org.apache.tomcat.service.TcpConnectionThread.run(SimpleTcpEndpoint.java:338)

        at java.lang.Thread.run(Thread.java:475)


If I remove the taglib entry in web.xml I get the same error

Any idea ?



--
Luc Margaron
Metrix Development
Tel   : (+33) 4 92 94 24 17
Fax   : (+33) 4 92 94 24 91



Mime
View raw message