You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Emmanuel KOJE <e....@yahoo.com> on 2007/01/24 12:16:21 UTC

Filter

Hi Guys,

I tried to configure a filter to get all my cookies from my request and set information some information in the request object.

Unfortunetly it seems It didn't keep the value I've set as a parameter of the request. Every time my request pqremeter is empty. Even if I do a setAttribute.
Can I use custom filter with Struts 2 ? or does the filter RequestDispacther override all my parameters ?

Thanks for your help


----- Original Message ----
From: Dave Newton <DN...@hibbertgroup.com>
To: Struts Users Mailing List <us...@struts.apache.org>
Sent: Tuesday, January 23, 2007 5:00:29 PM
Subject: RE: [s2] Question about SessionAware docs.

From: Tom Schneider [mailto:schneidh@gmail.com]
> Actually your explanation is not quite 100% correct.  The interceptor
> injects a Map that is backed by the HttpSession.  So puts and gets to
> the Map will actually be puts and gets to the HttpSession.  (Very 
> clever IMO)

Ah, okay. That's handy and still keeps it clean :)

Dave


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








 
____________________________________________________________________________________
Looking for earth-friendly autos? 
Browse Top Cars by "Green Rating" at Yahoo! Autos' Green Center.
http://autos.yahoo.com/green_center/

Re: Filter

Posted by Taras Puchko <ta...@gmail.com>.
Hi!

Request parameters should not be confused with request attributes. In
general you cannot set a parameter but you can make a wrapper for the
request object overriding getParameter(String), getParameterNames()
and getParameterValues(String).
You can also forward to a URL that contains your parameter.

Taras.

On 1/24/07, Emmanuel KOJE <e....@yahoo.com> wrote:
> Hi Guys,
>
> I tried to configure a filter to get all my cookies from my request and set information some information in the request object.
>
> Unfortunetly it seems It didn't keep the value I've set as a parameter of the request. Every time my request pqremeter is empty. Even if I do a setAttribute.
> Can I use custom filter with Struts 2 ? or does the filter RequestDispacther override all my parameters ?
>
> Thanks for your help
>
>
> ----- Original Message ----
> From: Dave Newton <DN...@hibbertgroup.com>
> To: Struts Users Mailing List <us...@struts.apache.org>
> Sent: Tuesday, January 23, 2007 5:00:29 PM
> Subject: RE: [s2] Question about SessionAware docs.
>
> From: Tom Schneider [mailto:schneidh@gmail.com]
> > Actually your explanation is not quite 100% correct.  The interceptor
> > injects a Map that is backed by the HttpSession.  So puts and gets to
> > the Map will actually be puts and gets to the HttpSession.  (Very
> > clever IMO)
>
> Ah, okay. That's handy and still keeps it clean :)
>
> Dave
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
>
>
>
>
>
>
>
> ____________________________________________________________________________________
> Looking for earth-friendly autos?
> Browse Top Cars by "Green Rating" at Yahoo! Autos' Green Center.
> http://autos.yahoo.com/green_center/
>

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