struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Howard Moore <Howard.Mo...@Datapulse.com>
Subject RE: initial action
Date Mon, 05 Mar 2001 17:49:33 GMT
If you are using Tomcat I believe that the problem is that the code checks
that the file exists before redirecting to it so doesn't work for URLs that
are mapped to a servlet. A workaround to this problem is to create a dummy
file with the same name. In your case this would be something like;

<TOMCAT_HOME>/webapps/<myApp>/index.do

The file doesn't have to contain anything in particular, it is never
accessed.

> -----Original Message-----
> From: Peter Alfors [mailto:peter.alfors@irista.com]
> Sent: 05 March 2001 17:27
> To: struts-user
> Subject: initial action
> 
> 
> Hello,
> 
>     I noticed some messages in the archives that explain how 
> to have the
> initial page be an action.
> It appears that adding this block:
> 
>    <welcome-file-list>
>      <welcome-file>index.do</welcome-file>
>    </welcome-file-list>
> 
> directly after the servlet definition in the web.xml should do the
> trick.  However, as others have replied, I am receiving the directory
> listing rather than executing the specified action.
> 
> Has anyone been able to get this to work?
> 
> Thanks,
>     Pete
> 

Mime
View raw message