so JSP1 should be associated with another Action, which fetch data from DB and setAttribute in request or session.
You should make your Action not the JSP1 available to the user. --- Sebastian Ho <[EMAIL PROTECTED]> wrote: > Hi > > Scenario : > > 1. User submits form in JSP1 which Action1 saves to > database. > 2. Action1 set Form1 into session. > 3. Action1 forwards to JSP1 again, which is suppose > to display newly > added form with other forms previously added. > > How do I make JSP1 to get values from database > BEFORE JSP1 displays and > set them into session? I suppose I have to do this > in Action1 but for > the first submission of form1, Action1 is not called > yet by JSP1. > > >From my analysis, there will be situation where > there will be multiple > input sources into a particular JSP. That means I > need to have my > 'update from database and set in session' codes in > all the Action > classes that forwards to JSP1? > > In another words, how do I call the update method in > Action1 from > Action2 before forwarding to the JSP which display > my updated data. > > This is duplication of codes and inefficient to me. > There must be a > better way to do this in Struts. > > My question might be confusing..I am trying my best. > Tell me if its > unclear. > > Thanks > > Sebastian Ho > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > > __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]