asp自动隐藏框

[复制链接]
查看11 | 回复0 | 2008-5-13 17:00:43 | 显示全部楼层 |阅读模式
document.write("#master{LEFT:0px;POSITION:absolute;}#menu{LEFT:-10px;POSITION:absolute; TOP:230px; Z-INDEX:5}#screen{POSITION:absolute; TOP:211px; Z-INDEX:5}#screenlinks{POSITION:absolute; TOP:219px; VISIBILITY:visible; Z-INDEX:5}") document.write('#screen{filter:Alpha(Opacity=60)') var master = new Object("element") master.curLeft = document.body.clientWidth+20; master.curTop = 10; function moveAlong(layerName, paceLeft, paceTop, fromLeft, fromTop){ clearTimeout(eval(layerName).timer) if(eval(layerName).curLeft != fromLeft){ if((Math.max(eval(layerName).curLeft, fromLeft) - Math.min(eval(layerName).curLeft, fromLeft))fromLeft){eval(layerName).curLeft = eval(layerName).curLeft - paceLeft} document.all[layerName].style.left = eval(layerName).curLeft } if(eval(layerName).curTop != fromTop){ if((Math.max(eval(layerName).curTop, fromTop) - Math.min(eval(layerName).curTop, fromTop))fromTop){eval(layerName).curTop = eval(layerName).curTop - paceTop} document.all[layerName].style.top = eval(layerName).curTop } eval(layerName).timer=setTimeout('moveAlong("'+layerName+'",'+paceLeft+','+paceTop+','+fromLeft+','+fromTop+')',30) } function setPace(layerName, fromLeft, fromTop, motionSpeed){ eval(layerName).gapLeft = (Math.max(eval(layerName).curLeft, fromLeft) - Math.min(eval(layerName).curLeft, fromLeft))/motionSpeed eval(layerName).gapTop = (Math.max(eval(layerName).curTop, fromTop) - Math.min(eval(layerName).curTop, fromTop))/motionSpeed moveAlong(layerName, eval(layerName).gapLeft, eval(layerName).gapTop, fromLeft, fromTop) } var expandState = 0 function expand(){ if(expandState == 0){setPace("master", document.body.clientWidth-200, 10, 10); document.menutop.src = "Images/tools.gif"; expandState = 1;} else{ setPace("master", document.body.clientWidth+20, 10, 10); document.menutop.src = "Images/tools.gif"; expandState = 0;} } document.write("

[img][/img]
"); var sidemenu = document.all.master; sidemenu.style.left=document.body.clientWidth+20;function yuzi(){ sidemenu.style.top = document.body.scrollTop+document.body.clientHeight-500;} setInterval("yuzi()",220); 使用以上代码能解决你提出的问题,但是你马上就会发现新的问题
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行