title: how to fill a table with array elements in jquery?
body: <p>i have a table in html like this:</p>
  
  <pre><code>&lt;table id="someTable"&gt;
     &lt;tr&gt;
         &lt;td&gt;
             &lt;span&gt;&lt;/span&gt;
         &lt;/td&gt;
     &lt;/tr&gt;
     &lt;tr&gt;
         &lt;td&gt;
             &lt;span&gt;&lt;/span&gt;
         &lt;/td&gt;
     &lt;/tr&gt;
     &lt;tr&gt;
         &lt;td&gt;
             &lt;span&gt;&lt;/span&gt;
         &lt;/td&gt;
     &lt;/tr&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>i have an array someArray with three values in it. I want to iterate through the array and set each array items to a span on each row.</p>
  
  <p>i tried a jquery code like this</p>
  
  <pre><code>$('#someTable tr').each(function(i) {
        $(this + 'td:first span').html(someArray[i]);
  });
  </code></pre>
  
  <p>the problem is it is setting the last value on the array to all the span's how to fix it?</p>