File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Tomcat and the fly likes Problem with Apache Tomcat 5.5.12 and calling Servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Reply locked New topic

Problem with Apache Tomcat 5.5.12 and calling Servlets

Kevin P Smith
Ranch Hand

Joined: Feb 18, 2005
Posts: 362
Hi guys, hope you can help...

I have two Servlets, one called LoginServlet & another called UploadServlet.

The problem I am having is, whilst my program will call/run the LoginServlet fine. When I
come to calling the UploadServlet, I get the following page error:

HTTP Status 404 - /admin/secure/uploader/UploadServlet
type Status report
message /admin/secure/uploader/UploadServlet
description The requested resource (/admin/secure/uploader/UploadServlet) is not available.
Apache Tomcat/5.5.12

There appears to be no error in the Tomcat logs to help explain what is going on. It's just like the Servlet class just isn;t
physically there (obviously it is).

Could someone help, it's really holding me up at the moment.

(Below are some details of file locations and stuff to help you out).

JSP location:
C:\Java\Tomcat 5.5\webapps\web\secure\uploader\upload.jsp

Form that calls Servlet:
<form name="frmUploader" action="UploadServlet" method="POST">

Servlet package:

Servlet class location:
C:\Java\Tomcat 5.5\webapps\web\WEB-INF\classes\uk\co\domain\servlets\UploadServlet.class

web.xml location:
C:\Java\Tomcat 5.5\webapps\web\WEB-INF\web.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "">
<web-app id="WebApp_1136308273688">
<servlet id="Servlet_1136308272594">
<servlet id="Servlet_1136308272595">

<servlet-mapping id="ServletMapping_1136308273704">
<servlet-mapping id="ServletMapping_1136308273705">

<welcome-file-list id="WelcomeFileList_1136308273703">
Amit Kumar Kaushik

Joined: Jan 12, 2006
Posts: 11
change the folloing line and try again.

<form name="frmUploader" action="http:\\localhost:8080\web\UploadServlet" method="POST">


<form name="frmUploader" action="/web/UploadServlet" method="POST">
Ben Souther

Joined: Dec 11, 2004
Posts: 13410

K Secker,

Please don't ask the same question multiple times in the same forum.
If the details from your first thread have changed, update that one.

Please continue this conversation in the original thread:

Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
I agree. Here's the link:
subject: Problem with Apache Tomcat 5.5.12 and calling Servlets
It's not a secret anymore!