I have a requirement where I need to generate a web page in that number of fields is not fixed,so I have to generate them dynamically using a plus button to add extra fields by users. Can somebody please assist me how can I go on this one and how to collect the values entered in those fields in java and persist them to DB as I can't fix number of table also.
I thought to use simple jsp tags or struts 2 tags but didn't come to know how can I do this. I hope you got my requirement correctly, my requirement is that "I need to have 3 fixed fields as a group and need to provide a plus button. on click of that plus button it should generate 3 more fields and so on" can you tell me how can I accomplish this?
1) Using just JSP: When the button is clicked, the page is submitted so that the JSP can be re-ecexcuted putting the desired number of fields on the page. Use <c:if> for making descisions, and <c:forEacj> for looping.