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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Servelet

Status
Not open for further replies.

youngun

Programmer
Apr 27, 2001
61
US
I am in a Unix Enviornment and have Tomcat installed as the server, and I also downloaded servlet classfiles from java.sun.com, when I unzip the classfiles, and it creates a directory "Javax" and inside "Javax", it is directory "servlet" with all the .class files inside. However, when I try to write a program and do the following:
import javax.servlet.*;
compiler error says that the package is not provided. Am I doing something wrong?

and How do I make sure that the Java virtual machine supports the Java platform servlet specification.

Thank you very much for your time,
 
you need to change your classpath to see the jar files.

in bash:
%> export CLASSPATH=.:<path_to_jakarta>/lib/webserver.jar
%> export CLASSPATH=$CLASSPATH:<path_to_jakarta>/lib/servlet.jar

and so on. You need to add each jar file to the classpath. I did this in my /etc/profile, as always, ymmv. leo

------------
Leo Mendoza
lmendoza@garbersoft.net
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top