找回密码
 注册
搜索
热搜: 回贴
  • 前程无忧官网首页 有什么好的平台可以
  • 最新的销售平台 互联网营销的平台有哪
  • 制作网页的基本流程 网页制作和网页设
  • 【帝国CMS】输出带序号的列表(数字排
  • 网站建设公司 三一,中联,极东泵车的
  • 织梦 建站 织梦网站模版后台怎么更改
  • 云服务官网 哪些网站有免费的简历模板
  • 如何建网站要什么条件 建网站要用什么
  • 吉林市移动公司电话 吉林省退休人员网
  • 设计类毕业论文 网站设计与实现毕业论
查看: 194|回复: 2

教程:表格里面的连续循环滚动的新闻

[复制链接]
发表于 2009-9-15 02:54:52 | 显示全部楼层 |阅读模式 IP:江苏扬州
请勿带外部链接,为别的网站做广告宣传,谢谢。 (2009-02-13 14:52)[HTML]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<script LANGUAGE="JavaScript">
<!--
function _InitScroll(_S1,_S2,_W,_H,_T){
return "var marqueesHeight"+_S1+"="+_H+";var stopscroll"+_S1+"=false;var scrollElem"+_S1+"=document.getElementById('"+_S1+"');with(scrollElem"+_S1+"){style.width="+_W+";style.height=marqueesHeight"+_S1+";style.overflow='hidden';noWrap=true;}scrollElem"+_S1+".onmouseover=new Function('stopscroll"+_S1+"=true');scrollElem"+_S1+".onmouseout=new Function('stopscroll"+_S1+"=false');var preTop"+_S1+"=0; var currentTop"+_S1+"=0; var stoptime"+_S1+"=0;var leftElem"+_S2+"=document.getElementById('"+_S2+"');scrollElem"+_S1+".appendChild(leftElem"+_S2+".cloneNode(true));setTimeout('init_srolltext"+_S1+"()',"+_T+");function init_srolltext"+_S1+"(){scrollElem"+_S1+".scrollTop=0;setInterval('scrollUp"+_S1+"()',50);}function scrollUp"+_S1+"(){if(stopscroll"+_S1+"){return;}currentTop"+_S1+"+=1;if(currentTop"+_S1+"==(marqueesHeight"+_S1+"+1)) {stoptime"+_S1+"+=1;currentTop"+_S1+"-=1;if(stoptime"+_S1+"=="+_T/50+") {currentTop"+_S1+"=0;stoptime"+_S1+"=0;}}else{preTop"+_S1+"=scrollElem"+_S1+".scrollTop;scrollElem"+_S1+".scrollTop +=1;if(preTop"+_S1+"==scrollElem"+_S1+".scrollTop){scrollElem"+_S1+".scrollTop=0;scrollElem"+_S1+".scrollTop +=1;}}}";
}

//-->
</script>

<title>无标题文档</title>
<style type="text/css">
<!--
UNKNOWN {
FONT-SIZE: 12px; FONT-FAMILY: Tahoma, Arial, Helvetica, sans-serif
}
body{
font-family: Arial, "宋体";
font-size: 12px;
color: #333333;
text-decoration: none;
line-height: 1.8;
margin:0;
text-align: justify;
text-justify:inter-ideograph;
background-color:#cecfce;
/*cursor:url(../images/df.cur); */
}
a {
font-size: 12px; color: #000000;
}
a:link {
font-size: 12px;text-decoration: none;
}
a:visited {
font-size: 12px;text-decoration: none;
}
a:hover {
font-size: 12px;text-decoration: none;color: #FFFFFF;
}
a:active {
font-size: 12px;text-decoration: none;

}
#content-news{
FLOAT: left; margin-left:9px;WIDTH: 483px;POSITION: absolute; HEIGHT:100%; border:#BDCFAD 1px solid;
}
-->
</style>
</head>

<body>

<div id="content-news">
<!--**********************列表**************************** -->
<div id=Scroll_news1>
<div id=Scroll_news2>
<table width="100%" border="0" cellspacing="0" cellpadding="0" >

<tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第1行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr><tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第2行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr>
<tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第3行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr>
<tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第4行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr>
<tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第5行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr><tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第6行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr><tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第7行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr>
<tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第8行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr>
<tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第9行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr>
<tr onmouseover="this.style.background='#cccc99'" onmouseout="this.style.background=''">
<td width="5%" height="30" align="center"><img src="http://www.isinwin.com/_isw_code/index_news-ico.gif" width="5" height="3" /></td>
<td width="80%"><a href="http://www.isinwin.com">第10行,点点看</a></td>
<td width="15%" align="center">2009-1-23</td>
</tr>

<tr>
<td height="30" colspan="3" align="center" class="bottom">--- End ---</td>
</tr>
</table>
</div></div></div>
<SCRIPT language=JavaScript>
eval(_InitScroll("Scroll_news1","Scroll_news2",483,30*5,1000));
//eval(_InitScroll("Scroll_reports1","Scroll_reports2",483,30*5,1000));
</SCRIPT>
</body>
</html>
[/HTML]
发表于 2010-2-10 09:05:07 | 显示全部楼层 IP:天津
美丽让男人停下,智慧让男人留下。
回复

使用道具 举报

发表于 2010-3-7 23:05:09 | 显示全部楼层 IP:江苏南京
我认为,如果不把楼主的帖子顶上去,就是对真理的一种背叛,就是对谬论的极大妥协
回复

使用道具 举报

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

本版积分规则

QQ|小黑屋|最新主题|手机版|微赢网络技术论坛 ( 苏ICP备08020429号 )

GMT+8, 2024-9-30 15:34 , Processed in 0.204705 second(s), 14 queries , Gzip On, MemCache On.

Powered by Discuz! X3.5

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表