I am using JQuery and I have a container (Div) sized 100 by 30,
and an image that is placed within it (sized 20×20).
I want some event handling to take place when the div is clicked
and different event handling to happen when the image is clicked.
I do not want the handler for the div to fire when the click is on the image.
how am I supposed to handle event binding and event propagation ?
Thanks
Either
return false;to stop propagation or useevent.stopPropagation():See also:
.bind():