I have a question about tag library descriptor. I specified in my JSP a URI for the taglibrary descriptor as "/hello". And I placed the tld file in Web-inf directory. The question is when I tried to open the JSP. Tomcat says can not open library descriptor "C:\tomcat\webapp\thisWebApp\hello" I don't know why tomcat doesn't recognize the taglib's uri and trace to the proper tld file but instead taking the uri somehow as a file and could not open it! Thanks for your help.
Despite its name, I'm not sure that that's a true URI, but actually a path. The usual approach would be to put your TLD in the WEB-INF directory (which isn't usually URL-accessible) and code the taglib definition like this: <%@ taglib uri="/WEB-INF/hello.tld" prefix="hi" %> That's from memory, so it may be a little garbled. You may want to RTFM just to make sure.
Sometimes the only way things ever got fixed is because people became uncomfortable.
I have the same problem. Look at my error message.... ========================================== org.apache.jasper.compiler.CompileException: /www/codejuice/webapps/onjava/welcome2.jsp(0,0) Unable to open taglibrary /WEB-INF/onjavataglib2.tld : Parse Error in the tag library descriptor: External parameter entity "%[dtd];" has characters after markup. ============================================ Have you found the solution ? Thanks. Wei Shung