This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

saving session variable in drop down list  RSS feed

 
divya kundapur
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

i have 2 session variables which has user selected values from 2 drop down lists. When the page reloads i want these 2 session variables to be displayed in the drop down lists. How can i use those session variables as values since the drop down lists gets data from a action class.
 
Bilal A. Siddiqui
Ranch Hand
Posts: 53
Android Chrome Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Add these session variables in your drop down list in action class itself.
 
Sagar Rohankar
Ranch Hand
Posts: 2907
1
Java Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
divya kundapur wrote:
i have 2 session variables which has user selected values from 2 drop down lists. When the page reloads i want these 2 session variables to be displayed in the drop down lists. How can i use those session variables as values since the drop down lists gets data from a action class.

Do you want to say, like " User selects two values from DD lists, and when they select those values, its get inserted into session ?"
 
divya kundapur
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sagar Rohankar wrote:
divya kundapur wrote:
i have 2 session variables which has user selected values from 2 drop down lists. When the page reloads i want these 2 session variables to be displayed in the drop down lists. How can i use those session variables as values since the drop down lists gets data from a action class.

Do you want to say, like " User selects two values from DD lists, and when they select those values, its get inserted into session ?"


I solved this issue, just had to use struts tags instead of plain html.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!