we have a list of domain objects needing to be edited on an html page. For example, the command & domain objects:
class MyCommand {
List<Person> persons;
}
class Person {
String fname;
String lname;
}
Then, the HTML I expect to have the Spring MVC tag libraries generate is like this:
<form>
<input name="persons[0].fname"> <input name="persons[0].lname"><br/>
<input name="persons[1].fname"> <input name="persons[1].lname"><br/>
<input name="persons[2].fname"> <input name="persons[2].lname"><br/>
...
<input name="persons[n].fname"> <input name="persons[n].lname"><br/>
</form>
But can't see how to express this using the Spring Form Tag Libraries (using Spring 2.5.6.). I want to use the tag libraries so that it takes care of binding existing values to the tags for editing (when they're there).
Any tips?