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

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定

各位大神,求解,為什么圖片不能邊寬,謝謝!??!

<!DOCTYPE html>

<html>

<head>

<meta charset="utf-8">

<title>baiyechuang</title>

<style type="text/css">

img{

width: 600px;

height: 310px;

}

</style>

</head>

<body>

<img src="1.jpg">

<img src="2.jpg">

<img src="3.jpg">

<img src="4.jpg">

<script type="text/javascript">

window.onload = function (){

var oimg=document.getElementsByTagName('img'),

timer=null;

for(var i=0;i<oimg.length;i++){

function start(target){

var speend=0;

if(target>this.style.width){

speend=1;

}else{

speend=-1;

}

if(this.style.width==target){

clearInterval(timer);

}else{

this.style.width=this.offsetWidth+speend+'px';

}

}

oimg[i].onmouseover=function(){

clearInterval(timer);

timer=setInterval(

start(400);

},30);

}

oimg[i].onmouseout=function(){

clearInterval(timer);

timer=setInterval(

start(310);

},30);

}

}


}

</script>

</body>

</html>


正在回答

1 回答

定時(shí)器沒(méi)有你那么寫(xiě)的吧。里面是一個(gè)匿名回調(diào)函數(shù)


oimg[i].onmouseover=function(){
?? ??? ??? ??? ??? ??? ??? ?
?? ??? ??? ??? ??? ??? ??? ?clearInterval(timer);
?? ??? ??? ??? ??? ??? ??? ?
?? ??? ??? ??? ??? ??? ??? ?timer=setInterval(
?? ??? ??? ??? ??? ??? ??? ?
?? ??? ??? ??? ??? ??? ??? ?start(400);
?? ??? ??? ??? ??? ??? ??? ?
?? ??? ??? ??? ??? ??? ??? ?},30);

仔細(xì)看,{} 明顯的嵌套不對(duì)

0 回復(fù) 有任何疑惑可以回復(fù)我~

舉報(bào)

0/150
提交
取消

各位大神,求解,為什么圖片不能邊寬,謝謝!??!

我要回答 關(guān)注問(wèn)題
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢(xún)優(yōu)惠詳情

幫助反饋 APP下載

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

公眾號(hào)

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