×

Loading...

How can I run a Servlet in Tomcat?

If I finish compiling my servlet program,
I want to run it in my browser.
Which absolute path shall I put?
Does Tomcat have any profile file that set the value of the path .
Just like Apache web server, we can set the value of the path: /home/httpd/cgi-bin/
so only the file in cgi-bin can run cgi programs.
I guess it's in Servlet path of Tomcat.
I copy my files(.java and .class) into the servlet example files path.But we I run it in my browser ,but the server didn't find it.
just like "http://192.168.1.20:8080/example/servlet/HttpExample"
(My file is HttpExample.class)

?
Report

Replies, comments and Discussions: