I'm still getting a 404.  Here's my setup.  I have index.jsp as my welcome file.  It 
does a forward to my main action.  I have a login filter in front of the main action, 
which checks the session for some user information.  The first time through, this 
obviously isn't there, so it does a HttpResponse.sendRedirect to my login action.  The 
login action displays the login JSP, or at least it tries to.  This is where I'm 
getting my 404.

web.xml:
  <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
  </welcome-file-list>

index.jsp:
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<html>
  <body>
    <logic:forward name="track"/>
  </body>
</html>

struts-config:
  <global-forwards>
    <forward name="track" path="/do/track"/>
  </global-forwards>

filter config:
   <filter>
      <filter-name>LoginFilter</filter-name>
      <filter-class>com.*****.cc.track.servlet.LoginFilter</filter-class>
      <init-param>
         <param-name>login-action</param-name>
         <param-value>/do/login</param-value>
      </init-param>
   </filter>
   <filter-mapping>
      <filter-name>LoginFilter</filter-name>
      <url-pattern>/do/track</url-pattern>
   </filter-mapping>

login action config:
    <action
      path="/login"
      type="com.*****.cc.track.struts.action.LoginDispatchAction"
      name="loginActionForm"
      scope="request"
      input="/WEB-INF/login.jsp"
      parameter="action"
      unknown="true"
      validate="false"
    >
      <forward
        name="track"
        path="/do/track"
        redirect="true"
      />
      <forward
        name="login"
        path="/WEB-INF/login.jsp"
        redirect="false"
      />

LoginDispatchAction performs
return mapping.findForward("login");
when no username/password have been sent to it, as will be the case when it is called 
from LoginFilter.

Anyone see any obvious problems with this configuration/implementation?  I know my 
login action is executing, as I've dropped in some log messages.

Also, what is ok to leave outside WEB-INF?  index.jsp/welcome.jsp, 404.jsp/500.jsp and 
similar pages?

Thanks.

-----Original Message-----
From: Jeff Kyser [mailto:[EMAIL PROTECTED]
Sent: Monday, September 29, 2003 14:35
To: Struts Users Mailing List
Subject: Re: How-to hide JSPs in WEB-INF (OT?)


Okay, then map all your action forwards to /WEB-INF JSP pages in your 
struts-config file.

that will work too.

-jeff

On Monday, September 29, 2003, at 01:26  PM, Fenderbosch, Eric wrote:

> I'll keep that in mind, but as I'm completely new to Struts, I'm 
> trying to do this one piece at a time so that have a better idea where 
> my problems are.  First generic struts, then add validator, then add 
> tiles.
>
> -----Original Message-----
> From: Jeff Kyser [mailto:[EMAIL PROTECTED]
> Sent: Monday, September 29, 2003 14:24
> To: Struts Users Mailing List
> Subject: Re: How-to hide JSPs in WEB-INF (OT?)
>
>
> I use tiles, and map all the JSPs (in my WEB-INF directory) to tile
> definitions.
> Works fine...
>
> -jeff
>
> On Monday, September 29, 2003, at 01:22  PM, Fenderbosch, Eric wrote:
>
>> Is there a how-to on hiding JSPs in WEB-INF?  I keep getting 404
>> errors after moving them there.  I google'd the problem, but didn't
>> really find a how-to, but did find a couple posts that say this might
>> be impossible with WebLogic 6.1.  Can anyone confirm or deny that?
>>
>> Thanks.
>>
>> Eric
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>


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



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

Reply via email to