T
tiewknvc9
Hi!
I know java well, however I am new at making java integrate with JSP.
What I have done, is created a class file (test.class) in a package
called testThis.
the test object contains an empty constructor, and is used to access
utility funcitons in the class file.
So testThis.test would lead me directly to the test object.
in my jsp application (running on tomcat), I have
<% @page import="java.io.*, testThis.*" %>
as my import statement.
my class is currently located in the classpath, AND in the
Tomcat\apache-tomcat-5.5.17\shared\classes folder AND in the
WEB-INF\classes folder. I just dont know what I am doing wrong...
thanks in advance!
When I try to run the page I get the following page exception...
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 6 in the jsp file: /purchase/fileupload.jsp
Generated servlet error:
test cannot be resolved to a type
An error occurred at line: 6 in the jsp file: /purchase/fileupload.jsp
Generated servlet error:
test cannot be resolved to a type
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
I know java well, however I am new at making java integrate with JSP.
What I have done, is created a class file (test.class) in a package
called testThis.
the test object contains an empty constructor, and is used to access
utility funcitons in the class file.
So testThis.test would lead me directly to the test object.
in my jsp application (running on tomcat), I have
<% @page import="java.io.*, testThis.*" %>
as my import statement.
my class is currently located in the classpath, AND in the
Tomcat\apache-tomcat-5.5.17\shared\classes folder AND in the
WEB-INF\classes folder. I just dont know what I am doing wrong...
thanks in advance!
When I try to run the page I get the following page exception...
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 6 in the jsp file: /purchase/fileupload.jsp
Generated servlet error:
test cannot be resolved to a type
An error occurred at line: 6 in the jsp file: /purchase/fileupload.jsp
Generated servlet error:
test cannot be resolved to a type
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)