Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Iterating over a Set session attribute  RSS feed

 
Deepan Ignatius
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have a Set variable added to session scope. I would like to know whether it is possible to access it from a jsp in order to iterate over it.

Java Code:



Is it possible to access the above session attribute 'relCauses' inside a jsp? and how to do it?

Thanks.
 
amit punekar
Ranch Hand
Posts: 544
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
Of course you can use it.
You need to use EL(Expression Language) to access the session scoped attributes and JSTL to iterate through it.

Regards,
Amit
 
Seetharaman Venkatasamy
Ranch Hand
Posts: 5575
Eclipse IDE Java Windows XP
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if the values are user specific information[limited values] then session is fine, otherwise you should use request scope.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!