Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Why the page import

Status
Not open for further replies.

alpaso

Programmer
Oct 30, 2003
9
US
When I try to run some jsps and beans that I created relative tothe examples directory I can run them fine without the <%@page import=...%> statement at the top of the jsps.
But when I try to run a newly created app from the webapps folder with jsps and objects/beans I canot get it to run without the <%@page import=...%> statement. The JSP thows the foll. error:
org.apache.jasper.JasperException: Unable to compile class for JSPNote: sun.tools.javac.Main has been deprecated.


An error occured between lines: 4 and 8 in the jsp file: /Name.jsp

Generated servlet error:
C:\Program Files\Apache Tomcat 4.0\work\localhost\TestNM\Name$jsp.java:59: Class org.apache.jsp.Name not found.
Name name = new Name();
^


Why is that?

Also there is another page that works with or without the <%@page import=...%> statement????
 
don't bother guys ..silly mistake on my part.
was not qualifiying the class. after I put my classes in a package it all worked!.
But I remember they did not work when I did not have them in a package and had them in the default package in classes folder. Is that Apache/Tomcat 's way to enforcing you to use packages?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top