Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Running servlets

 
Claudia Vaz
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I'm trying to run a servlet in Tomcat but i'm not hving much sucess.
In the classpath i have ".;c:\jdk1.3.1\src.jar;c:\jdk1.3.1\jre\lib\rt.jar;c:\jdk1.3.1\lib\tools.jar;c:\jdk1.3.1\lib\dt.jar,c:\jdk1.3.1\jre\lib\i18n.jar,c:\jakarta-tomcat-3.2.3\lib\servlet.jar" which has the path to the servlet.jar.
My servlet is in the directory TomcatHome/webapps/mydev/web-inf/classes.
When in this directory i execute the command
javac servletName.java
errors occurs.
Some of these error are:
"ServletName.java:1 cannot resolve symbol
symbol : class HttpServletResponse
location: class servletName
HttpServletResponse res)"
I think he does not recognize the servlet.jar

What i am doing wrong??? Does anynone can hep me!!!
Thanks
Claudia
 
Sagar Bilgi
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI claudia,
see my post in the same forum with topic " compiling servlets under tomcat 4.0"
As was suggested to me by mike I would specify the classpath of the servlet.jar when u are tryong to compile
ex javac - classpath "path to servlet.jar" yourfile.java
hope this helps..
Sagar
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic