Doug Ahmann wrote:
> Sorry to spam you all with what I hope is a simple config issue:
>
> Error: 500
> Location: /vserver/login.jsp
> Internal Servlet Error:
>
> org.apache.jasper.JasperException: Unable to open taglibrary
> /WEB-INF/struts.tld : Parse Error in the tag library descriptor: Element
> "web-app" does not allow "servlet" here.
> at
Ooh ooh ... I know this one :-)
You are running under Tomcat 3.something, right? Well, it turns out that Tomcat does
not validate the web.xml file when it loads your web application. However, when you
use a JSP page with a custom tag, the JSP page compiler parses web.xml again (to find
taglib declarations), and it *does* call the validating parser. That means you need to
have the elements in the web.xml file in the order required by the DTD. In your case,
you have a <servlet> element out of place.
In Tomcat 4.0, a validating parser is called even the first time that web.xml is read,
so that you will find out about such problems immediately.
> Doug
Craig