Js event bubbling problem solving thank you

now there is such a layout
I use a div to cover a picture
I want to click on the div (red area) anywhere I want to pop up
, but only around can pop up
meaning do not want the event added to the picture how to solve

Mar.10,2021

has nothing to do with bubbling.
div add clicks to control the show and hide. of the picture in the
event


is a layout problem that can be blocked in the front by positioning


this can be solved with event traversal, which can be solved by adding a style to the img element pointer-events:none; .

your description does not match the html structure. According to your html structure, it is not that I use a div to cover a picture , but a div that contains img elements

.

about event traversal, take a look at the blog post I wrote earlier = > event traversal

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1eab09c-47dfb.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1eab09c-47dfb.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?