码迷,mamicode.com
首页 > 其他好文 > 详细

标题时间-现在时间为--特效

时间:2014-11-05 10:45:40      阅读:187      评论:0      收藏:0      [点我收藏+]

标签:style   blog   http   io   color   ar   java   sp   div   

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>网页教程网为您报时,现在的时间为-石家庄编导-电表控制器</TITLE>
<SCRIPT language=JavaScript>
var clocktext, timeday;
var pagetitle = document.title;
function scroll() {
today = new Date();
sec = today.getSeconds();
hr = today.getHours();
min = today.getMinutes();
if (hr < 12) { timeday = " AM"; }
else { timeday = " PM"; }
if (hr > 12) hr = hr - 12;
if (hr <= 9) hr = "0" + hr;
if (min <= 9) min = "0" + min;
if (sec <= 9) sec = "0" + sec;
var clocktext = ":" + hr + ":" + min + ":" + sec + timeday;
clocktimer = setTimeout("scroll()", 1000);
document.title = pagetitle + clocktext;
}
if (document.all) scroll();
</SCRIPT>
</HEAD>
<BODY></BODY></HTML>

 

标题时间-现在时间为--特效

标签:style   blog   http   io   color   ar   java   sp   div   

原文地址:http://www.cnblogs.com/youtianxia/p/4075522.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!