Craig, Thank you for the feedback.  This is my first Servlet / Tomcat 
project and apparently I have some things confused.  Within my web 
application I do have a Servlet named, SAWSServlet.
It was my impression that when I export my application to a WAR file 
that I should  name it with the exact same name as the Servlet.  So 
I've created a war file called SAWSServlet.war, which when unpacked 
creates a SAWSServlet folder under the Tomcat webapps directory.

Also, to provide more of the details which you had asked about.
My initial logon JSP just has a simple form as follows:
<FORM action="/SAWSServlet" class="formClass" method="get" >
    <INPUT type="HIDDEN" id="action" name= "action" value="logon">
    <p>UserId: &nbsp;&nbsp;&nbsp;<INPUT type="TEXT" id="UserId" 
name= "UserId" width="50"></p>
    <p>Password: &nbsp;<INPUT type="PASSWORD" id="Password" 
name= "Password" width="50"></p>
    <p><INPUT type="SUBMIT" id="Submit" value="Logon" width="50"></p>
</FORM>

The URL generated when that form is submitted is:
http://localhost:8080/SAWSServlet/action=logon&userId=test&password=test

Is it possible to configure Tomcat so that when the form in my JSP is 
submitted that it will generate a URL such as:
http://localhost:8080/myServletsName?parm1=anAction&parm2=value2

Lastly, I used the auto-deploy feature of Tomcat and just placed my WAR 
file in the webapps directory.  Therefore I haven't made any 
modifications to conf/server.xml or conf/web.xml.

Again, thanks for all of the help!
Regards,
Randy

Quoting "Craig R. McClanahan" <[EMAIL PROTECTED]>:

> 
> 
> On Thu, 27 Mar 2003, Randy Curnutt wrote:
> 
> > Date: Thu, 27 Mar 2003 10:13:40 -0500
> > From: Randy Curnutt <[EMAIL PROTECTED]>
> > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>,
> >      Randy Curnutt <[EMAIL PROTECTED]>
> > To: Tomcat Users List <[EMAIL PROTECTED]>
> > Subject: Tomcat 4.1.18 config for Servlet ...
> >
> > I can't get Tomcat 4.1.18 to send a form "GET" to my Servlet.   My
> current
> > guess is that maybe the GET is being handled by the DefaultServlet.
>   I
> > checked my log file after starting Tomcat and then having the error
> occur.
> > In the log it looks like it maps to my servlet correctly but then
> it adds "
> > default: DefaultServlet.serveResource: Serving resource '/' headers
> and
> > data".
> > What does this mean?   Is it saying that the DefaultServlet is
> handling
> > these requests instead of my servlet?
> >
> > 2003-03-27 09:48:10 StandardHost[localhost]: Mapping request URI
> > '/SAWSServlet'
> > 2003-03-27 09:48:10 StandardHost[localhost]: Trying the longest
> context path
> > prefix
> > 2003-03-27 09:48:10 StandardHost[localhost]: Mapped to context
> > '/SAWSServlet'
> 
> You don't tell us the entire URL you are submitting, or how you've
> got
> your webapps organized, so the best we can do is guess, but this line
> is
> pretty revealing -- it implies that you are using a URL like this:
> 
>   http://localhost:8080/SAWSServlet
> 
> and you've got your web application in a directory named
> "/SAWSServlet"
> under webapps.  To make this work, you need to do one of the
> following:
> 
> * Use a different URL (http//localhost:8080/SAWSServlet/SAWSServlet)
>   -- note that it is pretty confusing to have a webapp and a servlet
>   using the same prefix.
> 
> * Make your web application the "default" webapp for this Tomcat
>   installation, by putting it in the "webapps/ROOT" directory.
> 
> Craig
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to