> Hi i have a jsp page with a button "capture student details". when that > button is pressed it has to display few user input fields on the same page > like "student Name", student id and few other fields . now user enters the > details of the student and when he press the button again the same set of > fields have to appear again in order to capture the 2nd student details. > how to achieve this? > >
As member of your action you can use a Map<String, String>. The Map-Key is the dynamic field name. You need some JS to generate a new input-field in the browser. As html-input-name you can use an OGNL expression like "map['fieldName']". That way struts can set the keys and values in your action's map. Regards, Christoph This Email was scanned by Sophos Anti Virus