📄 notice.asp
字号:
<%
exec_notice="select * from notice"
set rs1=server.createobject("adodb.recordset")
rs1.open exec_notice,conn,1,1
%>
<table width="350" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFCC">
<!--DWLayoutTable-->
<tr align="center">
<td width="1"> </td>
<td> <div style="width: 350px;overflow: hidden; background-color: #ffc;" onmouseover="clearInterval(timer1);" onmouseout="go();">
<div style="position: relative;top: 0px;left: 0px;white-space: nowrap;color: #000;" id="news">
<span id="nbo" style="color: #000;">
<%
do while not rs1.eof
response.Write rs1("notice_content")&" "
rs1.movenext
loop
rs1.close
%>
</span>
<script language="javascript">
document.write(nbo.innerHTML); //重复一次新闻内容
document.write(nbo.innerHTML); //重复一次新闻内容
document.write(nbo.innerHTML); //重复一次新闻内容
document.write(nbo.innerHTML); //重复一次新闻内容
document.write(nbo.innerHTML); //重复一次新闻内容
document.write(nbo.innerHTML); //重复一次新闻内容
document.write(nbo.innerHTML); //重复一次新闻内容
document.write(nbo.innerHTML); //重复一次新闻内容
</script>
</div>
</div>
<script language=javascript>
function newsScroll() { //实现不间断滚动
news.style.pixelLeft=(news.style.pixelLeft-1)%nbo.offsetWidth;
}
function go() {
timer1=setInterval('newsScroll()',20) //更改第二个参数可以改变速度,值越小,速度越快。
}
go();
</script> </td>
</tr>
</table>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -