setTimeout函数只是执行一次?
为什么调用该函数可以实现高度持续减小呢?????
function adDown(){
oAd.style.display = "block";
oAd.style.height = h+"px";
if( h<maxH ){
h+=step ; //向下移动
setTimeout(adDown,1);
}else{
setTimeout(adUp,3000); //停留时间自己适当调整 1000 = 1秒
}
}
为什么调用该函数可以实现高度持续减小呢?????
function adDown(){
oAd.style.display = "block";
oAd.style.height = h+"px";
if( h<maxH ){
h+=step ; //向下移动
setTimeout(adDown,1);
}else{
setTimeout(adUp,3000); //停留时间自己适当调整 1000 = 1秒
}
}
2016-11-24
举报