0
我在我的html中嵌入了一個soundcloud播放器,我將它放置在屏幕底部的固定位置,並設置爲在10秒後消失。即時通訊嘗試讓玩家在鼠標懸停在屏幕底部時重新出現(就好像有一個固定在屏幕上的不可見div)但是這不起作用。我如何讓玩家重新出現在屏幕底部的鼠標懸停上?如何讓玩家出現在鼠標懸停上
<!-- section to hover over to make Player visible -->
<div class="hover" align="center" id=‘a’ style="color:#3498db">
<style>
div.hover{
position: fixed;
height: 1000px;
bottom: 0;
right: 0;
width: 100%;
;
}
#b {
display: none;
}
#content:hover~#b{
display: block;
}
</style>
</div>
<!-- Soundcloud player and view code -->
<div class="fixed" align="center" id='b'>
<!--Player -->
<iframe width="100%" height="450" scrolling="no" frameborder="no" src="https://w.soundcloud.com/player/?url=https%3A//api.soundcloud.com/playlists/11450645&color=ff5500&auto_play=false&hide_related=false&show_comments=true&show_user=true&show_reposts=false"></iframe>
<!-- fixed position code -->
<style>
div.fixed {
position: fixed;
bottom: 0;
right: 0;
width: 100%;
;
}
<!-- Player hides after x seconds -->
div.fixed {
-webkit-animation: cssAnimation 0s ease-in 10s forwards;
-moz-animation: cssAnimation 0s ease-in 10s forwards;
-o-animation: cssAnimation 0s ease-in 10s forwards;
animation: cssAnimation 0s ease-in 10s forwards;
-webkit-animation-fill-mode: forwards;
animation-fill-mode: forwards;
}
@keyframes cssAnimation {
from {
visibility:hidden;
}
to {
width:0;
height:0;
visibility:hidden;
}
}
@-webkit-keyframes cssAnimation {
from {
visibility:hidden;
}
to {
width:0;
height:0;
visibility:hidden;
}
}
</style>
<!-- End of Soundcloud code -->
</div>