wood burning stoves*
The moose likes Servlets and the fly likes newbie- can't compile java servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Servlets
Bookmark "newbie- can Watch "newbie- can New topic
Author

newbie- can't compile java servlet

roland edwards
Greenhorn

Joined: Jul 23, 2001
Posts: 1
I'm trying to compile my servlet and I'm getting these messages:
package javax.servlet does not exist
package javax.servlet.http does not exist
I'm using Resin-2.0.1 servlet runner.
My path statement:
PATH C:\WINDOWS;C:\WINDOWS\COMMAND;C:\JAVA\JDK1.3.0_02\BIN;C:\JAVA\RESIN-2.0.1\LIB
The LIB directory is where all the JAR files for Resin are located. I assume the java libraries are in JAR files but I'm a newbie - who knows?
thanks for any help.
Subbu Aswathanarayan
Ranch Hand

Joined: Jun 22, 2001
Posts: 73
Hi,
you need to include ur servlet.jar file in your classpath
if you are using windows, insert the following line in ur autoexec.bat
SET CLASSPATH=%CLASSPATH%;<jdk root directory>\lib\servlets.jar

for eg if you have installed jdk in c:\ then ur jdk root direcory should be C:\JDK1.3
hope this helps.
Subbu

Subbu
 
GeeCON Prague 2014
 
subject: newbie- can't compile java servlet