Retrieve table id with jQuery
<p>I have some tables that are generated with automatic id, so I didn't know the table id before to do some stuff on it.</p>

<p>To retrieve my id, I use this jQuery light code </p>

<pre><code> $('table').each(function(){
                alert(this.id);
            });
</code></pre>

<p>Idea of the html code generated:</p>

<pre><code>&lt;table id="table1"&gt;...&lt;/table&gt;&lt;table id="table2"&gt;...&lt;/table&gt;
</code></pre>

<p>This jQuery code give me all table ids.<br>
My tables have some button to add rows, so if I click on the add button for the 2nd table, that only add the row for the 2nd table (the code upside give me all table id on my web page)</p>

<p>How can I retrieve the curent table id? (I have try to play with prev() but I think I don't play as well as I must do)</p>

<p>Note: I didn't need code to append a row, I could do that ;)</p>
