标题滚动效果演示

模板网 2015-07-31

纯JS实现的标题滚动效果。代码如下:

复制代码 代码如下:
<script type="text/javascript">
(function(){
    setInterval(function(){
        text = top.document.title;
        top.document.title=text.substring(1,text.length)+text.substring(0,1);
    },500);
})();
</script>
&lt;!DOCTYPE html&gt;
&lt;html&gt;
&lt;head&gt;
&lt;meta charset=&quot;gb2312&quot; /&gt;
&lt;title&gt;标题滚动效果演示——标题滚动效果演示&lt;/title&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
(function(){
    setInterval(function(){
        text = top.document.title;
        top.document.title=text.substring(1,text.length)+text.substring(0,1);
    },500);
})();
&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
标题滚动效果演示
&lt;/body&gt;
&lt;/html&gt;

相关文章

  1. JS兼容多种浏览器的设为首页和加入收藏夹代码

    JS兼容多种浏览器的设为首页和加入收藏夹代码,设为首页和加入收藏夹分别对应两个函数setHomePage,addFavorite。 示例代码: 设为首页:a href=javascript:; onclick=setHomePage(http://www.120muban.com/);设为首页/a 加入收藏夹:a href=javascript:; oncl

  2. 标题滚动效果演示

    纯JS实现的标题滚动效果。代码如下: 复制代码 代码如下: script type=text/javascript (function(){ setInterval(function(){ text = top.document.title; top.document.title=text.substring(1,text.length)+text.substring(0,1); },500); })(); /script

  3. 使用新浪获取IP所在地接口做网站跳转

    使用新浪获取IP接口做网站跳转 title使用新浪获取IP接口做网站跳转/title !--引用新浪IP获取接口-- script type=text/javascript src=http://int.dpool.sina.com.cn/iplookup/iplookup.php?format=js/script !--引用新浪IP获取接口-- script type=text/javas

  4. 从腾讯网提取的判断手机端访问跳转代码

    从腾讯网提取的判断手机端访问跳转代码,使用了一个正则表达式来判断浏览器的navigator.userAgent标志,来确认访问终端,从而做出相应的操作。 代码简单,注释详细,容易理解。 复制代码 代码如下: script type=text/javascript if(/Android|Windows Phone|w

  5. nTabs纯JS实现的标签切换功能代码

    nTabs纯JS实现的标签切换功能代码,使用非常方便。

随机推荐

  1. JS兼容多种浏览器的设为首页和加入收藏夹代码

    JS兼容多种浏览器的设为首页和加入收藏夹代码,设为首页和加入收藏夹分别对应两个函数setHomePage,addFavorite。 示例代码: 设为首页:a href=javascript:; onclick=setHomePage(http://www.120muban.com/);设为首页/a 加入收藏夹:a href=javascript:; oncl

  2. 标题滚动效果演示

    纯JS实现的标题滚动效果。代码如下: 复制代码 代码如下: script type=text/javascript (function(){ setInterval(function(){ text = top.document.title; top.document.title=text.substring(1,text.length)+text.substring(0,1); },500); })(); /script

  3. 使用新浪获取IP所在地接口做网站跳转

    使用新浪获取IP接口做网站跳转 title使用新浪获取IP接口做网站跳转/title !--引用新浪IP获取接口-- script type=text/javascript src=http://int.dpool.sina.com.cn/iplookup/iplookup.php?format=js/script !--引用新浪IP获取接口-- script type=text/javas

  4. 从腾讯网提取的判断手机端访问跳转代码

    从腾讯网提取的判断手机端访问跳转代码,使用了一个正则表达式来判断浏览器的navigator.userAgent标志,来确认访问终端,从而做出相应的操作。 代码简单,注释详细,容易理解。 复制代码 代码如下: script type=text/javascript if(/Android|Windows Phone|w

  5. nTabs纯JS实现的标签切换功能代码

    nTabs纯JS实现的标签切换功能代码,使用非常方便。