title: Using html tags with id+numbers to find them in jQuery
body: <p>Having an html code like this:</p>
  <pre><code>&lt;table&gt;
      &lt;tr&gt;
          &lt;td bgcolor=yellow&gt;LED #1&lt;/td&gt;
          &lt;td id=led0 bgcolor=red&gt;ON&lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
          &lt;td bgcolor=yellow&gt;LED #2&lt;/td&gt;
          &lt;td id=led1 bgcolor=red&gt;ON&lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
          &lt;td bgcolor=yellow&gt;LED #3&lt;/td&gt;
          &lt;td id=led2 bgcolor=red&gt;ON&lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
          &lt;td bgcolor=yellow&gt;LED #4&lt;/td&gt;
          &lt;td id=led3 bgcolor=red&gt;ON&lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
          &lt;td&gt;
              &lt;button&gt;number 1&lt;/button&gt;
          &lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
          &lt;td&gt;
              &lt;button&gt;number 2&lt;/button&gt;
          &lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
          &lt;td&gt;
              &lt;button&gt;number 3&lt;/button&gt;
          &lt;/td&gt;
      &lt;/tr&gt;
  &lt;/table&gt;
  </code></pre>
  <p>I would like to achieve something like this:</p>
  <pre><code>$('button').click(function() {
    var index = $(&quot;button&quot;).index(this);   
   // alert(index);
    $(&quot;#led[index]&quot;).html('&lt;div style=&quot;background:#cccccc&quot; &gt;OFF&lt;/div&gt;');
  
    
  });
  </code></pre>
  <p>In words: I want to detect the button pressed (which is already working) and then modify the html code of the td element with <code>id=&quot;led[index]&quot;</code> and using the variable <code>&quot;index&quot;</code> to find the right led number.</p>
  <p>Any idea?</p>