I have one html div on my jsp page, on that i have put one anchor tag, please find code below for that,
Change your jQuery code with this. It will alert the id of the a.
$('.expandable-panel-heading:not(#ancherComplaint)').click(function () { markActiveLink(); alert('123'); }); function markActiveLink(el) { var el = $('a').attr("id") alert(el); }
Demo