Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

my servlet doesnt work

 
maheshm morem
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
please some one help me,
i have make progogram and complied in javac compiler it it gives me error, as follow
packege javax.servlet doesnot exist.
what i have to do for this where i will get these package
 
Harpreet Singh janda
Ranch Hand
Posts: 317
Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is the package that contains the rquired class files for the servlet api.

You can google out the servlet-api.jar file or the same file can be found in lib directory of your tomcat.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check this FAQ.
 
Han Jie
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
servlet-api.jar does not in your classpath maybe
you can get it on jcp official website(latest release of it is 3.0 and i just got it) or proper lib of tomcat like the 2nd floor
both are ok

this is firsttime to be here, glad to meet you and others.!


 
Soumyajit Hazra
Ranch Hand
Posts: 136
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are using Tomcat then you will get the servlet_api.jar in "<Tomcat Home>\apache-tomcat-6.0.18\lib" location. If you are using websphere or weblogic then search for j2ee.jar and put it in classpath then compile your code.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic