Consider this.
one of the elements jquery offers is a modal dialog.
Basically, it provides a βscreenβ dialog box that sits above the rest of the screen so that you don't click on anything else on the page during the dialog.
div ... which is an element of a container, can contain several elements ... any element inside a div is still considered part of the div.
Now I'm not a professional when it comes to the structure and hierarchy of the DOM, but it seems to me that what you are trying to do will not work.
if there is something like a link inside a div, and jquery looks at the click event of this element. I would suggest that anything inside the div would be βbelowβ the screen provided by the div. so if you have a link inside a div and you click on the link, you also technically click on the div as well.
source share