<html>
<head>
<script type="text/javascript">
var mydate=new Date();
document.write(mydate+"<br/>");
var w=mydate.getDay();
document.write(w+"<br/>");
var e=["星期日","星期一","星期二","星期三","星期四","星期五","星期六"];
document.write("今天是星期"+e[w]+"<br/>" );
</script>
</head>
<body>
</body>
</html>
变量e 结尾的分号改成英文的就好