I have some HTML markup, similar to:
<div id="parentElement">
<div class="child"></div>
<div class="child"></div>
<div class="child"></div>
<div class="child"></div>
</div>
I am attaching an event handler to each child element with jQuery:
$( "div.child" ).on( "click", someFunction );
Is there an easy way for me to figure out which child element was triggered/clicked from the event object? For example, I'd like to be able to determine if the user clicked on the 3rd child <div>
versus one of the other child <div>
.