ITPub博客

首页 > IT职业 > IT图书 > 标题栏里的文字滚动的特效

标题栏里的文字滚动的特效

原创 IT图书 作者:chunzhisu 时间:2014-10-22 11:33:13 0 删除 编辑

点击(此处)折叠或打开

  1. <html>
  2.     <head>
  3.     <meta http-equiv=\"Content-Type\" content=\"text/html; charset=gb2312\">
  4.     <title>标题栏里的文字滚动的特效-石家庄花卉-草坪销售</title>
  5.     <script language=\"javascript\">
  6.     <!-- Hide me
  7.     var index_count = 0;
  8.     var title_string = \"欢迎光临『QQ空间站』 Welcome To XinQing Waystation\";
  9.     var title_length = title_string.length;
  10.     var cmon;
  11.     var kill_length = 0;
  12.     function loopTheScroll()
  13.     {
  14.     scrollTheTitle();
  15.     if(kill_length > title_length)
  16.     {
  17.     clearTimeout(cmon);
  18.     }
  19.     kill_length++;
  20.     cmon = setTimeout(\"loopTheScroll();\",100)
  21.     }
  22.     function scrollTheTitle()
  23.     {
  24.     var doc_title = title_string.substring((title_length - index_count - 1),title_length);
  25.     document.title = doc_title;
  26.     index_count++;
  27.     }
  28.     loopTheScroll();
  29.     //-->
  30.     </script>
  31.     </head>
  32.     <body>
  33.     </body>
  34.     </html>

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/29737856/viewspace-1306960/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2014-07-04

  • 博文量
    95
  • 访问量
    122217