jQuery Get Id of Clicked Element
$(document).ready(function() {
$("a").click(function(event) {
alert(event.target.id);
});
});
$(document).ready(function() {
$("a").click(function(event) {
alert(event.target.id);
});
});
$(document).on("click",".appDetails", function () {
var clickedBtnID = $(this).attr('id'); // or var clickedBtnID = this.id
alert('you clicked on button #' + clickedBtnID);
});
var rid = $(this).attr('id'); //for dynamically created elements