50分问个滚动效果的怪事,急急!

piperzero 2005-09-20 03:06:47
www.yilong.cc
问题如下,公司简介那里的滚动字幕有的时候是正常的,有的时候不正常(表现为上面留出一片空白)把版面搞坏了。就是换用最简单的marquee语言控制的时候依然是时好时坏。搞了两个小时无解,请各位帮忙。
滚动区代码
<table width="601" border="0" cellpadding="0" cellspacing="0" height="222">
<tr>
<td valign="top" width="302" align="center" > </td>
<td width="299" align="center" valign="top" background="Img/tdbackground5.gif">div id="icefable1">
<!-- #include file="gundong.asp" --></div>
</td>

</tr>


<script language="javascript">
marqueesHeight=180;
stopscroll=false;
with(icefable1){
style.width=0;
style.height=marqueesHeight;
style.overflowX="visible";
style.overflowY="hidden";
noWrap=true;
onmouseover=new Function("stopscroll=true");
onmouseout=new Function("stopscroll=false");
}
preTop=0; currentTop=180; stoptime=0;
icefable1.innerHTML+=icefable1.innerHTML;


function init_srolltext(){
icefable1.scrollTop=0;
setInterval("scrollUp()",10);
}
init_srolltext();

function scrollUp(){
if(stopscroll==true) return;
currentTop+=1;
if(currentTop==181)
{
stoptime+=1;
currentTop-=1;
if(stoptime==1)
{
currentTop=0;
stoptime=0;
}
}
else {
preTop=icefable1.scrollTop;
icefable1.scrollTop+=1;

if(preTop==icefable1.scrollTop){
icefable1.scrollTop=180;
icefable1.scrollTop+=1;

}
}

}

</script>
</table>
...全文
162 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
piperzero 2005-09-21
  • 打赏
  • 举报
回复
如果用层会出现上面的情况么?
piperzero 2005-09-20
  • 打赏
  • 举报
回复
dh20156(风之石) 但是他有时候又是好的,比如你刷新一下
dh20156 2005-09-20
  • 打赏
  • 举报
回复
看了下,可能是版面控制的问题,有地方错位了。
piperzero 2005-09-20
  • 打赏
  • 举报
回复
tigerwen01(小虎)(编程艺术化) ,你说的这个明显没有用么。
piperzero 2005-09-20
  • 打赏
  • 举报
回复
znjgress(学好VB.net!!!) ,我直接用marquee也是一样的,有时候也出问题,我想是不是服务器的问题。因为我本地测试好像不会出什么问题的。(因为网站速度的问题?)
tigerwen01 2005-09-20
  • 打赏
  • 举报
回复
marqueesHeight=220;
尚和空四 2005-09-20
  • 打赏
  • 举报
回复
直接 marquee 最好

28,406

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧