世界各国时间代码,留着备用!
2013-07-16 14:08
225 查看
世界各国时间代码,留着备用!代码如下:
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=gb2312″ />
<title>世界时间代码</title>
<style type=”text/css”>
*{margin:0px;padding:0px; font-size:12px;}
</style>
</head>
<body>
<div style=”width:1000px;line-height:30px;margin:0 auto; background:#ccc;”>
<TABLE height=15 cellSpacing=0 cellPadding=0 width=”96%” border=0>
<TR vAlign=top>
<TD vAlign=center nowrap class=”font1″>北京时间[<SPAN id=beijing></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>伦敦时间[<SPAN id=london></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>纽约时间[<SPAN id=newyork></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>芝加哥时间[<SPAN id=chicago></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>东京时间[<SPAN id=tokyo></SPAN>]</TD>
</TR>
</TABLE>
<SCRIPT language=javascript type=text/javascript>
//<![CDATA[
function time_rota()
{
var now;
var h,m,s;
now = new Date();
h=now.getHours();
m=now.getMinutes();
s=now.getSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.beijing.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota()", 1000);
}
time_rota();
function time_rota1()
{
var now;
var h,m,s;
now = new Date();
h=now.getUTCHours();
h -= -0;
if(h<0)
{h += 24;}
m=now.getUTCMinutes();
s=now.getUTCSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.london.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota1()", 1000);
}
time_rota1();
function time_rota2()
{
var now;
var h,m,s;
now = new Date();
h=now.getHours();
h -= 13;
if(h<0)
{h += 24;}
m=now.getMinutes();
s=now.getSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.newyork.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota2()", 1000);
}
time_rota2();
function time_rota3()
{
var now;
var h,m,s;
now = new Date();
h=now.getUTCHours();
h -= -9;
if(h<=0)
{h += 24;}
m=now.getUTCMinutes();
s=now.getUTCSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.tokyo.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota3()", 1000);
}
time_rota3();
function time_rota4()
{
var now;
var h,m,s;
now = new Date();
h=now.getUTCHours();
h -= 6;
if(h<=0)
{h += 24;}
m=now.getUTCMinutes();
s=now.getUTCSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.chicago.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota4()", 1000);
}
time_rota4();
//]]>
</SCRIPT>
</div>
</body>
</html>
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=gb2312″ />
<title>世界时间代码</title>
<style type=”text/css”>
*{margin:0px;padding:0px; font-size:12px;}
</style>
</head>
<body>
<div style=”width:1000px;line-height:30px;margin:0 auto; background:#ccc;”>
<TABLE height=15 cellSpacing=0 cellPadding=0 width=”96%” border=0>
<TR vAlign=top>
<TD vAlign=center nowrap class=”font1″>北京时间[<SPAN id=beijing></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>伦敦时间[<SPAN id=london></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>纽约时间[<SPAN id=newyork></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>芝加哥时间[<SPAN id=chicago></SPAN>]</TD>
<TD vAlign=center nowrap class=”font1″>东京时间[<SPAN id=tokyo></SPAN>]</TD>
</TR>
</TABLE>
<SCRIPT language=javascript type=text/javascript>
//<![CDATA[
function time_rota()
{
var now;
var h,m,s;
now = new Date();
h=now.getHours();
m=now.getMinutes();
s=now.getSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.beijing.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota()", 1000);
}
time_rota();
function time_rota1()
{
var now;
var h,m,s;
now = new Date();
h=now.getUTCHours();
h -= -0;
if(h<0)
{h += 24;}
m=now.getUTCMinutes();
s=now.getUTCSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.london.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota1()", 1000);
}
time_rota1();
function time_rota2()
{
var now;
var h,m,s;
now = new Date();
h=now.getHours();
h -= 13;
if(h<0)
{h += 24;}
m=now.getMinutes();
s=now.getSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.newyork.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota2()", 1000);
}
time_rota2();
function time_rota3()
{
var now;
var h,m,s;
now = new Date();
h=now.getUTCHours();
h -= -9;
if(h<=0)
{h += 24;}
m=now.getUTCMinutes();
s=now.getUTCSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.tokyo.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota3()", 1000);
}
time_rota3();
function time_rota4()
{
var now;
var h,m,s;
now = new Date();
h=now.getUTCHours();
h -= 6;
if(h<=0)
{h += 24;}
m=now.getUTCMinutes();
s=now.getUTCSeconds();
h=((h < 10) ? "0" : "") + h;
m=((m < 10) ? "0" : "") + m;
s=((s < 10) ? "0" : "") + s;
document.all.chicago.innerHTML = h+":"+m+":"+s;
setTimeout("time_rota4()", 1000);
}
time_rota4();
//]]>
</SCRIPT>
</div>
</body>
</html>
相关文章推荐
- 世界各国国家代码简称 - 备用
- Android世界时钟-时间1970-1-1 0:0无法设置的代码调用和原因
- Javascript 世界时区时间显示代码
- 状态栏世界时间_JS特效代码
- 世界各国语言代码
- android 世界各国英文简写代码 资源文件
- android 世界各国英文简写代码 资源文件
- 世界各国所使用的国际域名的缩写与电话代码对照表
- 世界各国浏览器语言代码对照表
- 世界各国国家代码简称
- Javascript 世界时区时间显示代码
- 世界各国英文简写代码
- 好用的android九宫格密码锁代码实现。(前段时间博客被盗好久没写了。)
- java获取时间整点工具代码
- C# 代码执行时间
- 各国股市开盘时间及开盘顺序
- 存一段代码备用,CopyPaste.cpp
- Mac/IOS/linux获取当前时间包含微秒毫秒的代码
- Jquery 绑定时间实现代码
- 10个超棒jQuery表单操作代码片段(留着备用)