aspose file tools*
The moose likes Servlets and the fly likes Problem With Tag Lib in Tomcat3.2.1 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Problem With Tag Lib in Tomcat3.2.1" Watch "Problem With Tag Lib in Tomcat3.2.1" New topic
Author

Problem With Tag Lib in Tomcat3.2.1

vaibhav punekar
Ranch Hand

Joined: Jan 20, 2001
Posts: 134
Hi,
I m using Tomcat3.2.1 I wish to create my own tags e.g. a tag for running exe,a tag for processing images etc.
I m not able to use it.Right now it is the error----------CompileException:UNABLE TO LOAD TAG LIBRARY.
I ve created my own web app in which I ve Meta-inf folder where I m saving my .tld file.And putting my ExeTag.class file in web-inf/classes.I ve added the tag in web.xml as well.
Please let me know what is the problem.I wish to go in for Standardisation as early as possible.
This is the error in the browser.---------------------
org.apache.jasper.compiler.CompileException: E:\jakarta-tomcat-3.2.1\webapps\upload1\uploadtag.jsp(67,0) Unable to open taglibrary http://localhost:8080/upload1 : null
at org.apache.jasper.compiler.JspParseEventListener.handleDirective(JspParseEventListener.java:713)
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:1077)
at org.apache.jasper.compiler.Parser.parse(Parser.java:1042)

VAIBHAV <BR>SCJP
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12835
    
    5
At least you got a clear exception - it must be a problem with either the way you defined the taglib or the way you refer to it in the JSP. Here is what worked for me in web.xml to define a taglib.
<taglib>
<taglib-uri>JSPbook/taglib</taglib-uri>
<taglib-location>
/WEB-INF/jsp/JSPbook-taglib.tld
</taglib-location>
</taglib>
And in the JSP
<body>
<%@ taglib uri="JSPbook/taglib" prefix="ch11" %>
Bill
------------------
author of:
vaibhav punekar
Ranch Hand

Joined: Jan 20, 2001
Posts: 134
Hi,
Thanks Wiliam.First of all glad to see RANCH HAND under my name.Right now error is
-----------------------------------------------------------------
org.apache.jasper.JasperException: No such tag Exetag in the tag library imported with prefix test
at org.apache.jasper.compiler.TagLibraries.isUserDefinedTag(TagLibraries.java:96)
at org.apache.jasper.compiler.Parser$Tag.accept(Parser.java:781)
at org.apache.jasper.compiler.Parser.parse(Parser.java:1077)
at org.apache.jasper.compiler.Parser.parse(Parser.java:1042)
at org.apache.jasper.compiler.Parser.parse(Parser.java:1038)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:182)
at org.apache.jasper.servlet.JspServlet.doLoadJSP(JspServlet.java:462)
at org.apache.jasper.servlet.JasperLoader12.loadJSP(JasperLoader12.java:146)
at org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:433)
at org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:152)
at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:164)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:318)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:210)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
at java.lang.Thread.run(Thread.java:484)
maha anna
Ranch Hand

Joined: Jan 31, 2000
Posts: 1467
Vaibhav,
I have Tomcat 3.1 installed in home machine. Here is the procedure I use for taglibs.
http://www.javaranch.com/ubb/Forum7/HTML/002817.html
regds
maha anna

[This message has been edited by maha anna (edited April 17, 2001).]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem With Tag Lib in Tomcat3.2.1