Sasikumar Subramanian <[EMAIL PROTECTED]> writes:
> Hi All,
>
> According to Servlet 2.4 Specification (9.10), We can use servlets
> as welcome file for an web module.
>
> <servlet>
> <servlet-name>TestServlet</servlet-name>
> <servlet-class>myweb.TestServlet</servlet-class>
> </servlet>
> <servlet-mapping>
> <servlet-name>TestServlet</servlet-name>
> <url-pattern>/testservlet</url-pattern>
> </servlet-mapping>
> ...
> <welcome-file-list>
> * <welcome-file>testservlet</welcome-file> or
> **<welcome-file>TestServlet**</welcome-file> ????????????*
> </welcome-file-list>
>
> My Question is which value would be specified in <welcome-file> tag.
> i.e., <servlet-name> value or <url-pattern> value??
Neither. You just specify a welcome file that will cause a servlet to
match.
eg:
<welcome-file-list>
<welcome-file>/testservlet</welcome-file>
</welcome-file-list>
or if you have a JSP and an CGI servlet loaded:
<welcome-file-list>
<welcome-file>/index.jsp</welcome-file>
<welcome-file>/index.cgi</welcome-file>
</welcome-file-list>
The reason for this is that the welcome file name is actually returned
as a redirect response to a client issuing a request for a blank
directory.
--
Nic Ferrier
http://www.tapsellferrier.co.uk
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html