【发布时间】:2020-03-16 02:23:29
【问题描述】:
我有一个与我联系的按钮,但是,每当有人将鼠标悬停在该按钮上时,我希望出现一个全屏图像背景。但是,此图像不是全屏的。
a {
text-decoration: none;
color: white;
/*Let's Chat colour*/
}
.Oval {
position: relative;
font-family: 'Open Sans', sans-serif;
top: 510px;
text-align: center;
font-size: 25px;
text-color: white;
left: 30%;
z-index: 75;
background-color: orange;
width: 140px;
height: auto;
background: #162129;
border-radius: 40px;
padding: 0px;
text-decoration: none;
}
.Oval:hover {
position: relative;
}
.Oval:hover:after {
content: url(Lightning1.JPG);
display: block;
position: absolute;
center: 100%;
top: -510px;
opacity: 0.5;
z-index: -10;
height: 100%;
width: 100%;
}
<div class="Oval"><a href="mailto:">Let's Chat</a></div>
【问题讨论】:
-
你能给我图片吗?喜欢尝试上传到imgur
标签: html css image frontend visual-web-developer