All:
I have two , overlap partially, top one has class "top", bottom one has class "bottom", what I want to do is trigger both onclick event when I click the overlap area.
How can I do that?
The HTML is like:
.bottom {
width: 300px;
height: 200px;
position: absolute;
background-color: tomato;
left: 100px;
top: 100px;
opacity: 0.5;
}
.top {
width: 300px;
height: 200px;
position: absolute;
background-color: lightseagreen;
left: 200px;
top: 200px;
opacity: 0.8;
}
<div class="bottom"></div>
<div class="top"></div>
I want to try event propagation, but this parallel structure seems not for it.
Any suggestion and code example will be appreciated.