Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java Open Source > Apache Tomcat
|
Apache Tomcat General discussion of the Apache Tomcat servlet container. For discussions specific to the Professional Apache Tomcat book, please see the book discussion forum for that book.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Apache Tomcat section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old March 24th, 2005, 07:19 AM
Registered User
 
Join Date: Mar 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Configuration problem (Java Servlets)

Hello, I am also having a problem with my Tomcat's configuration (verstion 5.5.7) but this has to do with running my java servlets which have been put in the appropriate directory but I still get an error 404 message. I reckon it has to do with my java home and classpath settings but I have followed all instructions and still get this error message. Can somebody help me please?
 
Old March 31st, 2005, 05:19 PM
Friend of Wrox
 
Join Date: Jul 2004
Posts: 204
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Can you tell if the servlets have compiled, if so the classpath is ok and its your directive to the servlet folder.

If there are no java class files in the folder then you have failed to compile.



 
Old March 31st, 2005, 05:35 PM
Registered User
 
Join Date: Mar 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes they did compile and the class files are present in the folder.

 
Old April 17th, 2005, 06:44 AM
Authorized User
 
Join Date: Apr 2005
Posts: 71
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Did you map the servlet classes with the url pattern in web.xml file?

It would be something similar to the following.

<servlet>
  <servlet-name>Hello</servlet-name>
  <servlet-class>exercise.HelloWorldServlet</servlet-class>
 </servlet>

 <servlet-mapping>
  <servlet-name>Hello</servlet-name>
  <url-pattern>/Hello</url-pattern>
 </servlet-mapping>

In case you are calling servlets from other web pages, make sure you have used correct url pattern.





Similar Threads
Thread Thread Starter Forum Replies Last Post
PHp & Java Configuration maheshoo7 PHP How-To 1 July 4th, 2007 08:03 AM
Java / XSLT configuration project fbrody XSLT 1 February 23rd, 2007 09:46 PM
Good Project in JDBC,JSP,Servlets,Java Beans Pooja J2EE 3 August 26th, 2004 08:05 AM
Windows Integrated Security with Java Servlets tbpbanit01 Servlets 0 March 24th, 2004 08:57 AM
Code for Professional Java Servlets 2.3 jure1 Wrox Book Feedback 3 August 24th, 2003 09:55 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.