Response title
This is preview!
How can I find ID of the element which caused an event as a consequence of .live (jQuery method) ?
The following is an example :
$("form[data-f=true]").live("submit", function (evt) { /* If I have <input type="submit" name="Submit1" data-f="true" /> and this button is clicked, then I want to know it's Submit1 button. */ });
I tried evt.target but it returns information about the form not about the button which was clicked.
Many thanks
© 2013 jQuery Foundation
Sponsored by and others.