Tag: 浏览器跨浏览器

IE兼容性模式:“X-UA兼容”标签“边缘”

我在<head>有这个: <meta http-equiv="X-UA-Compatible" content="IE=Edge" /> 它会强制IE的最新渲染模式,但兼容模式被认为是最后一个? 我的意思是,例如:使用这个代码与IE8,它会强制它使用IE8或IE8兼容模式?

跨浏览器(IE8-)getComputedStyle与Javascript?

由于IE8不支持getComputedStyle ,我们只能使用currentStyle 。 但是,它不会返回某些属性的实际“计算”值。 例如: <style type="text/css"> #div {/* no properties are defined here */} </style> <div id="div">div</div> // returns "medium" instead of 0px document.getElementById('div').currentStyle.borderLeftWidth // returns "auto" instead of 0px document.getElementById('div').currentStyle.marginLeft // returns "undefined" instead of 1 document.getElementById('div').currentStyle.opacity 有没有人有没有使用jQuery或其他Javascript库的所有属性的跨浏览器解决scheme?

从JavaScript添加到浏览器collections夹/书签,但对于所有浏览器(我的Chrome不起作用)?

任何人都可以帮助,我使用以下添加书签到IE和Firefox,但它不在Chrome中工作,我不会得到我的错误消息说“不支持”或者.. 任何人都知道一个好的脚本来支持所有的浏览器或至less回来告诉我它不支持,我有权访问jQuery – 也许有一些方法来检测浏览器 我目前使用这个,它适用于IE和Firefox,但不是铬 if (window.sidebar) { // Mozilla Firefox window.sidebar.addPanel(name, url, ""); } else if (window.external) { // IE window.external.AddFavorite(url, name); } else if (window.opera && window.print) { window.external.AddFavorite(url, name); } else { alert('not supported'); }

IE 6和IE 7的Z指数问题

http://madisonlane.businesscatalyst.com 我试图让div#的签署职位上面的div#底部。 除IE6和IE7以外的所有浏览器都能正常工作。 任何人都可以看到这里的问题是什么? 此外IE6显示额外的198px到div#底部的顶部。

修复Internet Explorer中的JavaScript数组函数(indexOf,forEach等)

如其他地方详细说明的那样,另外显然众所周知的是,Internet Explorer(绝对版本7,以及某些情况下,版本8)不实现关键函数,特别是在Array (比如forEach , indexOf等)。 在这里和那里有很多解决方法,但是我想将合适的,规范的实现集合放到我们的站点中,而不是复制,粘贴或者破解我们自己的实现。 我find了js-methods ,看起来很有希望,但是我以为我会在这里看看另一个库是否更受推荐。 一些其他的标准: 对于浏览器已经实现的那些函数( js-methods在这里performance得相当好),这个库应该是一个没有操作的东西。 非GPL ,请尽pipeLGPL是可以接受的。