设为首页 | 加入收藏
当前位置:首页>>网页特效>>状态栏特效>> 让你的标题栏文字动起来,标题也动了

让你的标题栏文字动起来,标题也动了

时间:2005-1-14 22:14:23 来源:本站收集整理 作者:佚名

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>滚动标题</title>
<script language="javascript">
<!-- Hide me
var index_count = 0;
var title_string = "让你的标题栏文字动起来,标题也动了,真有趣=====让你的标题栏文字动起来,标题也动了,真有趣-->3lian.com";
var title_length = title_string.length;
var cmon;
var kill_length = 0;
function loopTheScroll()
{
scrollTheTitle();
if(kill_length > title_length)
 {
 clearTimeout(cmon);
 }

kill_length++;
cmon = setTimeout("loopTheScroll();",100)
}

function scrollTheTitle()
{
var doc_title = title_string.substring((title_length - index_count - 1),title_length);
document.title = doc_title;

index_count++;
}


loopTheScroll();

//-->
</script>

</head>

<body>

</body>

</html>