I'm getting an interesting Tomcat/JSTL error which I couldn't find answer for.

It happens when running Tomcat and Jakarta JSTL standalone, or in Eclipse Platform, Version: 3.0.0.

Mac OS X Server 10.3.5
Standard current J2SE SDK:
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_05-141.3)
Java HotSpot(TM) Client VM (build 1.4.2-38, mixed mode)

4.1.30 Tomcat (the same happens for Tomcat 4.1 with mail.jar and activation.jar added from 4.1.30)
- out of box
- added libs: mysql JDBC, a proprietary 3rd party lib (not related to taglibs)


Tomcat 4.1.30 is 2.3 servlet, 1.2 JSP container, and according to jakarta JSTL docs, it works with JSTL 1.0 ("standard"). I'm using Jakarta JSTL 1.0.6 downloaded from jakarta website as that's where JSTL 1.0 "standard" points to.

I've put TLDs to app's WEB-INF, and JARs to WEB-INF/lib.

Now, when putting following to apps' web.xml, Tomcat complains about DTD at startup. Some JSP examples mention use of taglib; some JSTL examples doesn't mention it for core TLD, but does for special ones (scriptfree.tld, permittedTaglibs.tld). So I'm not using:
<taglib>
<taglib-uri>http://java.sun.com/jstl/core</taglib-uri>
<taglib-location>/WEB-INF/c.tld</taglib-location>
</taglib>


JSPs use following line:
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core"; %>

Some JSP examples use <taglib-uri>http://jakarta.apache.org/... but that didn't work as well. There's http://java.sun.com/jstl/core in c.tld file, so that's what I used. c.tld has <tlib-version>1.0</tlib-version>.


When using this configuration (with no <taglib> in web.xml), Tomcat *occasionally* fails after it's re/started and when there are java and class files under webapps/app-dir/work/org/apache/jsp. It generates following error. It's fine after java files get deleted (no need for Tomcat restart).


"Occasionaly" means it happens after a Tomcat re/start, when JSPs are jaspered to java already, and neither JSP nor class/lib files were changed.

org.apache.jasper.JasperException: Unresolved compilation problems:
org.apache.taglibs cannot be resolved or is not a type
org.apache.taglibs cannot be resolved
org.apache.taglibs cannot be resolved or is not a type
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja va:254)


Any idea what the [true] problem might be, and how to solve it, please?


________________________________________________________________________ IMPORTANT NOTICE:

Information contained in this e-mail is intended for the use of the addressee only, is 
confidential and may be legally privileged.  Any dissemination, distribution, copying 
or use of this communication without prior permission of the sender is strictly 
prohibited.

While this email has been scanned for viruses, the contents of any attachments to this 
email may contain software viruses which could damage your own computer system. Whilst 
every reasonable precaution has been taken to minimise this risk, we cannot accept 
liability for any damage which you sustain as a result of software viruses. You should 
therefore carry out your own virus checks before opening the attachment.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to