第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

我想做一個網(wǎng)頁效果,就是刷新頁面圖片透明度慢慢改變

我想做一個網(wǎng)頁效果,就是刷新頁面圖片透明度慢慢改變

sunsay 2018-10-16 20:25:57
<!DOCTYPE html><html><head> <title></title></head><style type="text/css"> html,body,div{ padding: 0; margin: 0; } .heads{ width: 100%; height: 60px; background-color: white; position: fixed; } .bigbox img{ width: 100%; top: 0px; } .img1{ width: 100% top:0px; height: 1500px; overflow: hidden; position: absolute; position: relative; left: 100px; top: 100px; /*transition: all all 1.5s cubic-bezier(0.25, 0.1, 0.71, 1.26) 0s;*/ opacity: 0.5; } .img1 img{ /*position: absolute; height: 0px; width: 100%;*/ } .v{ height: 550px; width: 100%; background-color: white; position: absolute; top: 1200px; } .x{ height: 550px; width: 100%; background-color: white; position: absolute; top: 2700px; }</style><body><div class="heads"></div><div class="bigbox"> <div class="img1"> <img src="C:\Users\unyu\Desktop\text\img\water_3840.jpg"> </div> <!-- <div class="img2"> <img src="C:\Users\unyu\Desktop\text\img\rain_3840.jpg"> </div> --> <div class="v"> <div class="text1"></div> </div> <div class="x"> <div class="text2"></div> </div></div><script>//let img1 = document.getElementById('img1');window.onload = function() { //img1.style.top=1000 + "px";document.getElementById(img1).style.opacity=1;}</script></body></html>
查看完整描述

2 回答

?
聰明的湯姆

TA貢獻112條經(jīng)驗 獲得超33個贊

推薦使用css3的animation

img?{
??animation:?fade-in?0.5s?ease-in;
}

@keyframes?fade-in?{
??from?{
????opacity:?0
??}
??to?{
????opacity:?1
??}
}

望采納!

查看完整回答
2 反對 回復(fù) 2018-10-17
?
JohnTito

TA貢獻2條經(jīng)驗 獲得超0個贊

css添加動畫也行

查看完整回答
反對 回復(fù) 2018-10-17
  • 2 回答
  • 0 關(guān)注
  • 1526 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號