I have a .jsp page where I have 3 struts tags (1 checkbox, 1 select tag, 1 textfield) and below these I have anchor tag to add more fields. So, when you click the anchor tag the javascript will add the 3 struts field below the one existing (something like attach file function in gmail). I am allowing maximum five field additions. However I have questions that when the user fills all these fields and clicks submit how can I collect all the data as the name attribute for all the 3 struts fields are only declared once and rest is dynamic addition using javascript. please help...........
sample code------below
---
and then you get dynamically same fields below this...so how should I collect all the data and display them in another .jsp page..
sample code------below
Code:
<s:checkbox name="chec" id="chec"></checkbox> <s:select name="file" id="file" value="email; TXT; voicemai></select> <s:textfield name="text" id="text"></textfield><br> <a href="javascript:adduploat(4,'chec', 'file', 'text')">add more fields</a>
and then you get dynamically same fields below this...so how should I collect all the data and display them in another .jsp page..
Comment