Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to compile a servlet using javac.exe?

 
Ben Gao
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I use " javac.exe -classpath C:\tomcat\common\lib XXXServlet.java" under command line.A error of "package javax.servlet does not exist" occurs.Would you tell me where the package javax.servlet locate. I can't find it.
Thank you!
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's in a jar file called servlet.jar.

If you download tomcat, you'll find it under <CATALINA_HOME>/common/lib
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic