首页 > 其他 > 详细

IE8 不支持Date.now()

时间:2014-10-16 12:23:53      阅读:304      评论:0      收藏:0      [点我收藏+]

Date.now()

返回1970 年 1 月 1日午夜与当前日期和时间之间的毫秒数。

 

以下是微软的描述:

在早于 Internet Explorer 9 的安装版本中不受支持。 但是,在以下文档模式中受到支持:Quirks、Internet Explorer 6 标准、Internet Explorer 7 标准、Internet Explorer 8 标准、Internet Explorer 9 标准和 Internet Explorer 10 标准。 在 Windows 应用商店 应用程序中也受支持。

http://msdn.microsoft.com/zh-cn/library/ie/ff679974(v=vs.94).aspx

 

但是经测试在IE8,标准模式下并未支持!

 1 <!DOCTYPE html>
 2 <html>
 3     <head>
 4         <meta charset="utf-8">
 5         <title>Date.now</title>
 6     </head>
 7     <body>
 8         <h1>Hello world.</h1>
 9         <script>alert(Date.now())</script>
10     </body>
11 </html>

bubuko.com,布布扣

IE8 不支持Date.now()

原文:http://www.cnblogs.com/zhouwenhong/p/4028436.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!