首先是插入超文本 然后帖进去以下的语句,注意符号一定要是英文状态下的,时分秒可以按照需求来删除
<script type="text/javascript">
var currentDate = new Date();
document.write("<span style='font-size:12px;'>"+currentDate.getFullYear() + "-"
+ (currentDate.getMonth()+1) + "-"
+ currentDate.getDate() + " "
+ currentDate.getHours() + ":"
+ currentDate.getMinutes()+":"
+ currentDate.getSeconds()
+ "</span>");
</script>