That happens (as described in the docs) because
Events created with
.triggerHandler()
do not bubble up the DOM hierarchy; if they are not handled by the target element directly, they do nothing.
and since you use the delegated syntax of the .on()
method which lets body
handle the click
event that occurs on the #hdimage
element, that event never reaches the body
..