How to create one javascript/jquery function-handler for many items?
<p>I have the html like below: </p>

<pre><code>&lt;table class="table" id="subscriptions"&gt;
  &lt;tbody id="subscriptions-tbody"&gt;
    &lt;tr&gt;
      &lt;td&gt;Item 1&lt;/td&gt;
      &lt;td&gt;&lt;a href="#"&gt;delete&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Item 2&lt;/td&gt;
      &lt;td&gt;&lt;a href="#"&gt;delete&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Item 3&lt;/td&gt;
      &lt;td&gt;&lt;a href="#"&gt;delete&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;
</code></pre>

<p>Items can be added dynamically there.</p>

<p>Now, I should create the function, which will help me to delete the element from the list, if user clicks delete. 
Looks like I should:</p>

<ol>
<li>assign some unique id for each item in the list (I have such ids) - where should I keep them? part as <code>href</code>?;</li>
<li>once user clicks on the link, I should prevent default action and pass control to my function (it will hide the element from the list and will sent POST request to the server) with item id as parameter.</li>
</ol>

<p>How to do it?</p>
