I am trying to run a sample custom tag java application. I get this error:
org.apache.jasper.JasperEx
ception: /index.jsp(23,4) Unable to load tag handler class "java.TestTagClass" for tag "tt:TestTag"
I have double and triple checked all of the paths and directory structure but the error remains the same.
Here is what I have:
The directory structure starts with the root at: c:\Java Projects\WebStuff\WebAppli
cation3
I think these are the important files:
build\web\index.jsp
build\web\WEB-INF\classes\
java\TagTe
st.class
build\web\WEB-INF\lib\jstl
.jar
build\web\WEB-INF\lib\stan
dard.jar
build\web\WEB-INF\tlds\TLD
Test.tld
build\web\WEB-INF\web.xml
here are some code snippets:
index.jsp:
<%@ taglib uri="TheTag" prefix="tt"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"
http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<h1>JSP Page</h1>
<tt:TestTag/>
</body>
</html>
__________________________
__________
__________
web.xml:
<web-app xmlns="
http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="
http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4">
<session-config>
<session-timeout>
30
</session-timeout>
</session-config>
<welcome-file-list>
<welcome-file>
index.jsp
</welcome-file>
</welcome-file-list>
<taglib>
<taglib-uri>TheTag</taglib
-uri>
<taglib-location>/WEB-INF/
tlds/TLDTe
st.tld</ta
glib-locat
ion>
</taglib>
</web-app>
__________________________
__________
__________
_
TLDTest.tld:
<taglib version="2.0" xmlns="
http://java.sun.com/xml/ns/j2ee" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
http://java.sun.com/xml/ns/j2ee web-jsptaglibrary_2_0.xsd"
>
<tlib-version>1.0</tlib-ve
rsion>
<short-name>tt</short-name
>
<uri>/WEB-INF/tlds/TDLTest
</uri>
<tag>
<name>TestTag</name>
<tagclass>java.TestTagClas
s</tagclas
s>
</tag>
</taglib>
__________________________
__________
__________
_
I suspect that for some reason the java.TestTagClass in not being found because I can change the <tagclass> value to anything and I get the same error.
I really want to get this thing to work so I can move on-- your help is appreciated!
Thanks