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 December 26th, 2003, 12:56 PM
Registered User
Join Date: Dec 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default not able to find classfile mapping through web.xml

   I have written a servlet program named ContextServlet that will dislay on the output

out.println("<head><title>Context Servlet</title></head>");

This servlet class file is in

....webapps\ch02app\web-inf\classes\chapter2 directory.

The web.xml file for this is

<?xml version="1.0" encoding="ISO-8859-1 "?>
<!DOCTYPE web-app
PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">



This web.xml is in web-inf folder. I am trying to execute this servlet by giving the following URL in Netscape7/IE browser

But I am getting the following error message
   HTTP Status 404 - /context
   The requested resource (/context) is not available.

I am using tomcat4 and jdk1.3 on Windows 98.

Is there any CLASSPATH setting required. If so where and what do I set it. Is the web.xml correct. How do I know whether it is getting parsed and if not, is a special parser required?? Each time I have changed web.xml I have bounced the tomcat server. I have added a CLASSPATH for my servlet in autoexec.bat and have restarted my machine. I dont know what else to do. Please advice. Mail to winnithr@yahoo.com

Best Regards,
Old January 2nd, 2004, 02:07 AM
Registered User
Join Date: Jan 2004
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts

I have the same trouble.But I think you could try by changing the fold name "web-inf" to "WEB-INF".

Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I find the codes of this book on your web? smilepww C# 0 August 19th, 2005 01:46 AM
mapping repeating xml structure to flat csv f vasmallela Biztalk 0 May 29th, 2005 11:53 PM
Where can I find the code of C# Web Services? herostone All Other Wrox Books 2 November 8th, 2004 08:54 AM
Get Servlet without mapping in web.xml Abhijitsaha2000 Servlets 1 August 9th, 2004 04:17 AM
XML to (different <tag>) XML mapping Thodoris XML 4 April 27th, 2004 04:02 AM

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