tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Duffy <duff...@yahoo.com>
Subject Servlet Mapping URL Pattern
Date Wed, 23 Apr 2003 21:06:42 GMT
I have another fundamental question.

I'm writing an application with a servlet in it.  I
package the app into a WAR file and deploy it on
Tomcat using Ant.  

There are JSPs in the app that refer to this servlet
in their <form> action.

If the name of my WAR file is app.war, and the
<servlet-name> in the web.xml is appServlet, what
should the URL pattern be in the <servlet-mapping>?

Should it look like:

<servlet-mapping>
<servlet-name>appServlet</servlet-name>
<url-pattern>/app/servlet/appServlet</url-pattern>
</servlet-mapping>

I used /appServlet as my URL pattern, but when I
invoke in from a JSP Tomcat complains that the servlet
is not available.  There are no error messages in any
of the log files.  I can see that the init parameters
are being found, so the servlet is there.  It's when I
call doPost() that there's a problem.  Any advice?


__________________________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo
http://search.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message