But I want this to happen for every action - and it is dependent on the request data that comes in.
Wes -----Original Message----- From: Lukasz Lenart [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 10, 2008 2:51 PM To: Struts Users Mailing List Subject: Re: How to set session data based on request parameters and how to retrieve session values correctly via OGNL Hello! 2008/6/10 Gamble, Wesley (WG10) <[EMAIL PROTECTED]>: > 1) I would like to set some session key-value pairs in response to a > request parameter so that I can count on these session variables > throughtout my application. Should I use an interceptor for this? How > does the interceptor get access to the request variables? > Your action class has to implement SessionAware interface and simply add your key-value to Map provided by setSession(Map session), that's all, no magic ;-) > 2) Assuming that I have correctly set my session values, how do I > correctly use them in a JSP. > <s:property value="#session.yourKey"/> Regards -- Lukasz http://www.lenart.org.pl/ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]