for me it works like this
<servlet>
<servlet-name>
Controller
</servlet-name>
<servlet-class>
de.datadesign.fb.web.servlets.Controller
</servlet-class>
</servlet>
<!-- mapping comes after servlet definitions -->
<servlet-mapping>
<servlet-name>
Controller
</servlet-name>
<url-pattern>
/jsp/lehrbank/controller
</url-pattern>
</servlet-mapping>
Your servlet tag seems to work, otherwise you wouldn't find it with this
url:
> http://localhost/Gillette/servlet/Venus?SerialId=ZVXZV&ContactId=1
because here you call it Venus, not GVservlet
but your mapping tag doesn't seem to work. You need the mapping tag to map a
servlet to a specific URL.
Are you using tomcat standalone or with apache? Maybe your apache doesn't
redirect this to tomcat because it is not under servlet and doesn't end with
jsp.
Try calling it Venus.jsp in the mapping and see if it works then. If it does
then it has something to do with your apache configuration (or other
webserver).
> I need my URL to look like this:
>
> http://localhost/Gillette/Venus?SerialId=ZVXZV&ContactId=1
> where Gillette is a directory and Venus is the servlet name.
> I can only
> get it to work if I include 'servlet' like the following:
>
> http://localhost/Gillette/servlet/Venus?SerialId=ZVXZV&ContactId=1
>
> I've got a few good responses in previous postings but
> haven't been able to
> get it to work. Here is some configurations....can anybody
> tell me what
> I'm doing wrong?
>
> server.xml:
> <Context path="/Gillette" docBase="webapps/Gillette"
> crossContext="false"
> debug="0" reloadable="true" ></Context>
>
> web.xml:
> <servlet>
> <servlet-name>Venus</servlet-name>
> <servlet-class>GVservlet</servlet-class>
> </servlet>
>
> <servlet-mapping>
> <servlet-name>Venus</servlet-name>
> <url-pattern>/Venus</url-pattern>
> </servlet-mapping>
>
> I've tried it with and without the servlet-mapping tag. Any ideas?
>
>
> Jason E. Brawner
>