This week's book giveaway is in the Java 8 forum.
We're giving away four copies of Java 8 in Action and have Raoul-Gabriel Urma, Mario Fusco, and Alan Mycroft on-line!
See this thread for details.
The moose likes Struts and the fly likes How to get session values in struts2 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "How to get session values in struts2" Watch "How to get session values in struts2" New topic
Author

How to get session values in struts2

saravanan Senthil
Greenhorn

Joined: Jan 11, 2013
Posts: 11
Hi,
I am new to struts2 I am working with session with session aware.while login I set values in sessionmap and i need these values in my other java class how do i get session values.please help me
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8715
    
    6

What is the "other class"? An action? You would need to make it session aware. If the other class is a business logic class or data access object, you'd need to pass the information from the action.


"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
saravanan Senthil
Greenhorn

Joined: Jan 11, 2013
Posts: 11
Joe Ess,
Hi I need session values in my action class and these action class are used by ajax call in jquery
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: How to get session values in struts2
 
Similar Threads
struts2
struts2
Pagination in Struts2
Struts2
Struts2 iterator