• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

preserving session formbeans

 
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello
I am using a html:link to transfer directly to a global forward that is actually an action. The problem is I need a formbean member value that I know positively, and visually, is in the bean before I html:link forward="", but it is not there in the action. This action works correctly when I use it in the "preload" stage with the desired form bean member populated. After one iteration I again see that the desired form bean member is populated, but when come in from the html:link it is null. What struts tag can I use to preserve the full state of my session attributes and formbean and forward to an action? tia.
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If the actions are configured with the same form bean the form should still be in the session. If your form has a reset() I'm not sure what the behavior would be.
 
Chris Pat
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi David
Thank you.
That is what I find so peculair. The formbean is the same throughout. On my "reenter" page, the one that has the html:link, I am using jstl to prove that the member of the formbean is there and has the values expected. Problem is when I click on the link and take it into the action it is null. This is struts1. The forward is a global forward that just points to the default context action *.do. I know how totally odd this is. Is there a way of getting the class of a formbean in a session to print out?
 
Chris Pat
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Sorry, move along, grin
I had set the scope to request and guess what that works. Reset it to session and all is well. Sorry for the intrusion of an unnecessary inscrutable.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
    Bookmark Topic Watch Topic
  • New Topic