permaculture playing cards
The moose likes Servlets and the fly likes tomcat & servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "tomcat & servlet" Watch "tomcat & servlet" New topic

tomcat & servlet

Aishwarya Choudhari

Joined: Feb 01, 2001
Posts: 2
I am using Tomcat web server for servlets.
I want to know when we write a servlet program & the related .html file ,in which folder should they be stored?i.e.I am storing it in (suppose i have unzipped the file in tomcat folder)tomcat\webapps\examples\servlets.
when i store the servlet program in this folder & i try the url http://localhost:8080/examples/servlets/***.java
(*** any servlet file name)
i get the correct output.
but if i store the .java files in any other folder i do not get any o/p.
Please let me know what i am doing is correct??
thanks in advance
Tualha Khan
Ranch Hand

Joined: Nov 22, 2000
Posts: 287
As far as I know, you have to set a Context name for this directory in the Server.xml file in the tomcat/conf directory. See some documentation and maybe you will work it out.
Tualha Khan

SCJP2, BEA WLS 6.0, DB2 UDB 7.1
I agree. Here's the link:
subject: tomcat & servlet
It's not a secret anymore!