<title>无标题文档</title>
<style type="text/css">
p:first-letter{ font-size:28px}
</style>
</head>
<body>
<div id="webjx"></div>
<script>setInterval("webjx.innerHTML=new Date().toLocaleString()+' 星期'+'日一二三四五六'.charAt(new Date().getDay());",1000);
</script>
<p style="width:100px; height:25px; line-height:25px;text-overflow:ellipsis;overflow:hidden; white-space:nowrap;">即可到圣诞节啥考试死定了</p>
<a style="display:inline-block;width:100px; height:25px; line-height:25px;text-overflow:ellipsis;overflow:hidden; white-space:nowrap;" href="#" title="即可到圣诞节啥考试死定了">即可到圣诞节啥考试死定了</a>
<!--要实现溢出时产生省略号的效果还须定义:强制文本在一行内显示(white-space:nowrap)及溢出内容为隐藏(overflow:hidden),只有这样才能实现溢出文本显示省略号的效果。 -->
支持所有的浏览器
</body>
</html>
网上找的,试过,可以撒;
<script>setInterval("webjx.innerHTML=new Date().toLocaleString()+' 星期'+'日一二三四五六'.charAt(new Date().getDay());",1000);
</script>
这个,是可以更新当前时间的,不错的方法,可以用一下下