You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by "Parambathu Kandy, Yasser Arafat (Cognizant)" <Ya...@cognizant.com> on 2006/02/06 09:42:57 UTC

how to get portlet session variable in a struts action

Hi,



This is my problem.

Page A: has 5 portlets. In one of them there is a combo. I choose a
value and hit submit.

It goes to the portlet's processAction where I sendRedirect to as psml
having 4 new portlets. This psml is Page B.

One of the portlets in page B is a struts bridge portlet. I need to get
the session attribute value in the Struts user action class set in Page
A portlet.



Things I Tried:

I set the value in portletSession in Page A and retrieved using
HttpSession in Page B's struts action. I got a null.





To put my question in a single sentence,

"How do I get the portletSession attribute value ,set in a portlet , in
an action class invoked by StrutsPortlet? "





Thanks in advance,



Yasser









This e-mail and any files transmitted with it are for the sole use of the intended recipient(s) and may contain confidential and privileged information.
If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
Any unauthorized review, use, disclosure, dissemination, forwarding, printing or copying of this email or any action taken in reliance on this e-mail is strictly
prohibited and may be unlawful.

  Visit us at http://www.cognizant.com

Re: how to get portlet session variable in a struts action

Posted by Ate Douma <at...@douma.nu>.
Parambathu Kandy, Yasser Arafat (Cognizant) wrote:
> Hi,
> 
> 
> 
> This is my problem.
> 
> Page A: has 5 portlets. In one of them there is a combo. I choose a
> value and hit submit.
> 
> It goes to the portlet's processAction where I sendRedirect to as psml
> having 4 new portlets. This psml is Page B.
> 
> One of the portlets in page B is a struts bridge portlet. I need to get
> the session attribute value in the Struts user action class set in Page
> A portlet.
> 
> 
> 
> Things I Tried:
> 
> I set the value in portletSession in Page A and retrieved using
> HttpSession in Page B's struts action. I got a null.
> 
> 
> 
> 
> 
> To put my question in a single sentence,
> 
> "How do I get the portletSession attribute value ,set in a portlet , in
> an action class invoked by StrutsPortlet? "
a) both portlets must be part of the portlet application (same war file)
b) use PortletSession.APPLICATION_SCOPE for setAttribute

> 
> 
> 
> 
> 
> Thanks in advance,
> 
> 
> 
> Yasser
> 
> 
> 
> 
> 
> 
> 
> 
> 
> This e-mail and any files transmitted with it are for the sole use of the intended recipient(s) and may contain confidential and privileged information.
> If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
> Any unauthorized review, use, disclosure, dissemination, forwarding, printing or copying of this email or any action taken in reliance on this e-mail is strictly
> prohibited and may be unlawful.
> 
>   Visit us at http://www.cognizant.com


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