title: keeping track of multiple related input boxes using spring mvc
body: <p>we have a list of domain objects needing to be edited on an html page.  For example, the command &amp; domain objects:</p>
  
  <pre><code>class MyCommand {
      List&lt;Person&gt; persons;
  }
  
  class Person {
      String fname;
      String lname;
  }
  </code></pre>
  
  <p>Then, the HTML I <em>expect</em> to have the Spring MVC tag libraries generate is like this:</p>
  
  <pre><code>&lt;form&gt;
     &lt;input name="persons[0].fname"&gt;&amp;nbsp;&lt;input name="persons[0].lname"&gt;&lt;br/&gt;
     &lt;input name="persons[1].fname"&gt;&amp;nbsp;&lt;input name="persons[1].lname"&gt;&lt;br/&gt;
     &lt;input name="persons[2].fname"&gt;&amp;nbsp;&lt;input name="persons[2].lname"&gt;&lt;br/&gt;
     ...
     &lt;input name="persons[n].fname"&gt;&amp;nbsp;&lt;input name="persons[n].lname"&gt;&lt;br/&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>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).</p>
  
  <p>Any tips?</p>