<script type="text/javascript">
//取得系统当前时间
function getTime(){
var myDate = new Date();
var date = myDate.toLocaleDateString();
var hours = myDate.getHours();
var minutes = myDate.getMinutes();
var seconds = myDate.getSeconds();
$("#showDate").html(date+" "+hours+":"+minutes+":"+seconds); //将值赋给div
}
window.setInterval("getTime()",1000); //每一秒刷新
</script>