077.标题栏鼠标座标- -| 回首页 | 2005年索引 | - -079.百度搜索

078.标题栏显示时间- -

Tag标题栏    显示    时间                                          

标题栏显示时间:
IE的标题实现出现时间的方法,相当不错。


<!-- Begin

var clocktext;

var pagetitle = document.title;

function scroll() {

today = new Date();

sec = today.getSeconds();

hr = today.getHours();

min = today.getMinutes();

if (hr <= 9) hr = "0" + hr;

if (min <= 9) min = "0" + min;

if (sec <= 9) sec = "0" + sec;

var clocktext = " 现在时间是: " + hr + ":" + min + ":" + sec;

clocktimer = setTimeout("scroll()", 1000);

document.title = pagetitle + clocktext;

}

if (document.all) scroll();

//  End -->

</script>

演示:

- 作者: xtfcyd 访问统计: 2005年09月10日, 星期六 18:52 加入博采

Trackback

你可以使用这个链接引用该篇文章 http://publishblog.blogchina.com/blog/tb.b?diaryID=2877858

博客手拉手

[2005-08-20]    Blog标题栏特效

[2005-08-28]    自动记录、显示页面更新时间

[2005-08-04]    时间规律

[2005-09-02]    追赶时间

[2005-09-02]    追赶时间

回复

评论内容: