I have a link like
<a href="#" id="foo" class="bar_link">blah</a>
I have many of these and the id value is an integer corresponding to a record in a database.
I want to create a click handler to pass the id attribute value for a specific link into a function whenever that link is clicked.
Here is what I have tried, but I am not having success.
$(".bar_link").live('click', barDetailsInit($(this).attr('id')));
What do you think? Thx!