这是帮助按钮>>
<a class="birthday-help" title="click for more information" role="button" href="#birthday[enter image description here][1]-help">
<img class="question" src="question1.png">
</a>
我想在同一页面上单击按钮时显示以下 div,(如弹出)
<div id="birthday-help" class="birthday-help-div">
= example text =
</div>
function birthdayHelp(){
let popup = document.getElementById("birthday-help");
popup.style.display="flex"
}
#birthday-help {
display:none;
justify-content:center;
align-items:center;
background-color:#000;
height:100vh;
width:100vw;
opacity:100%;
color:red;
font-size:24px;
font-weight:bold;
}
<a class="birthday-help" title="click for more information" role="button" href="#birthday[enter image description here][1]-help" onclick="birthdayHelp()">
<img class="question" src="https://www.searchpng.com/wp-content/uploads/2019/02/Help-Button-PNG-715x735.png" height=100px width=100px>
</a>
<div id="birthday-help" class="birthday-help-div">
Happy Birthday
</div>
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句