1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
function ima(id)
{
date = new Date;
year = date.getFullYear();
month = date.getMonth();
months = new Array('1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12');
d = date.getDate();
day = date.getDay();
days = new Array('日', '月', '火', '水', '木', '金', '土');
h = date.getHours();
if(h<10)
{
h = "0"+h;
}
m = date.getMinutes();
if(m<10)
{
m = "0"+m;
}
s = date.getSeconds();
if(s<10)
{
s = "0"+s;
}
result = '('+days[day]+')・'+year+'年'+months[month]+'月'+d+'日';
document.getElementById(id).innerHTML = result;
setTimeout('ima("'+id+'");','1000');
return true;
}
|