<!--中文日期-->
<script>
function change(dt)
{
var temp="";
switch(dt)
{
case "1": temp="一";
break;
case "2": temp="二";
break;
case "3": temp="三";
break;
case "4": temp="四";
break;
case "5": temp="五";
break;
case "6": temp="六";
break;
case "7": temp="七";
break;
case "8": temp="八";
break;
case "9": temp="九";
break;
default:temp="零";
}
return temp;
}
function showDate()
{
var now=new Date();
var year=now.getYear();
var yy=change(year.toString().substring(0,1))+change(year.toString().substring(1,2))
+change(year.toString().substring(2,3))+change(year.toString().substring(3,4));
document.write("当前日期: 公元"+yy+"年");
}
showDate();
</script>
<script>
function change(dt)
{
var temp="";
switch(dt)
{
case "1": temp="一";
break;
case "2": temp="二";
break;
case "3": temp="三";
break;
case "4": temp="四";
break;
case "5": temp="五";
break;
case "6": temp="六";
break;
case "7": temp="七";
break;
case "8": temp="八";
break;
case "9": temp="九";
break;
default:temp="零";
}
return temp;
}
function showDate()
{
var now=new Date();
var year=now.getYear();
var yy=change(year.toString().substring(0,1))+change(year.toString().substring(1,2))
+change(year.toString().substring(2,3))+change(year.toString().substring(3,4));
document.write("当前日期: 公元"+yy+"年");
}
showDate();
</script>