title: Get id of element on button click using jquery
body: <p>i have list of dynamic generated buttons and id is generated on run time. how can is get id of clicked button using JQuery. </p>
  
  <p>Here is js code </p>
  
  <pre><code>var btn = " &lt;input type='button' id='btnDel' value='Delete' /&gt;";
  
  
  $("#metainfo").append(txt); //set value of
  
  $("#btnDel").attr("id", "btnDel" + $("#hid").attr("value")); 
  </code></pre>