I think the simpler way is:

(1)Implement all your inputs in one Action and one JSP
(2)Control the visibility of your inputs via JQuery

In your case, you can put your inputs in 3 divs(or something else),
and bind click event handler to the buttons.
In the handler function,
you can call [show] to display the [next/prev] part
and call [hide] to hide the current part.

See:
http://api.jquery.com/show/
http://api.jquery.com/hide/



2010/11/1 Maurizio Cucchiara <maurizio.cucchi...@gmail.com>:
> looks like workflow interceptor thing
> http://struts.apache.org/2.2.1/docs/workflow-interceptor.html
>
> 2010/10/31 Per Johansson <perj...@gmail.com>:
>> Hi,
>>
>> What is the best practise for implementing a flow with more than one JSP
>> page in Struts 2.
>>
>> Example:
>>
>> Page 1:
>> Form with input fields
>> Next button
>>
>> Page 2:
>> Needs input from Page 1
>> Form with other input fields
>> Previous button
>> Next button
>>
>> Page 3:
>> Needs input from Page 1 and Page 2
>> Form with other input fields
>> Previous button
>> Submit button
>>
>>
>> Questions:
>> * One Action class, or three (code duplication)?
>> * Best way to pass data from page 1 to page 2, and from page 1 and 2 to page
>> 3?
>> * If one Action class, how to validate only page 1, or page 2 or page 3
>> input?
>>
>> /Best regards, Per Johansson
>>
>
>
>
> --
> Maurizio Cucchiara
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
> For additional commands, e-mail: user-h...@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org

Reply via email to