tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hans Bergsten <>
Subject Re: question about what this error means...
Date Fri, 21 Jul 2000 20:22:45 GMT
Jeff Ward wrote:
> the tld file has to be in your (webroot)/WEB-INF directory (it may be
> META-INF in apachee). So putting it in the same directory as the JSP doesn't
> work.

It should work according to the specification, so if it doesn't it's a bug
in Tomcat. Did you test this with the latest nightly build?

The JSP specification (and the errata document) describes how the TLD
is located. Basically, there are three options for the taglib directive
uri attribute:

1) <%@ taglib uri="foo.tld" prefix="xxx" %>
   The uri value doesn't start with a slash so it's interpreted as a
   path relative to the JSP page. In this example it must be located
   in the same directory.

2) <%@ taglib uri="/WEB-INF/tlds/foo.tld" prefix="xxx" %>
   The uri value starts with a slash so it's interpreted as a context-
   relative path. In this example it's located in the WEB-INF/tlds
   subdirectory for the web application.

3) <%@ taglib uri="/WEB-INF/lib/foo.jar" prefix="xxx" %>
   The uri value is a JAR file path, which could be with or without a
   slash as in 1) and 2). The TLD must be located in the META-INF/taglib.tld
   in the JAR file. I don't think Tomcat 3.1 and 3.2 Beta 2 supports this

4) <%@ taglib uri="/someName" prefix="xxx" %>
   The uri value is a symbolic name that is defined in the web.xml file
   by a <taglib> elements. The location is defined by the <taglib-location>
   subelement, using the same type of values as described for the uri
   attribute in 1) through 3).

Hans Bergsten
Gefion Software

View raw message