我对html5shiv脚本有点问题。它在IE8中不工作>-
Preview here:此脚本正在使用中:
<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->已测试:
<script type="text/javascript">
document.createElement('header')
document.createElement('footer')
document.createElement('main')
document.createElement('section')
document.createElement('nav')
</script>在样式之前和之后加载脚本。
所有的html5元素都有这样的标准样式:(在两个脚本之后加载)
article, aside, details, figcaption, figure, footer, header, hgroup, nav, section { display: block; }
audio, canvas, video { display: inline-block; *display: inline; *zoom: 1; }
audio:not([controls]) { display: none; }
[hidden] { display: none; } 不幸的是,在谷歌、stackoverflow和html5shiv文档网站上没有找到任何合适的解决方案。已尝试此处答案中的所有提示/技巧。但是它还是不能工作。
发布于 2014-01-18 19:25:13
尝试在底部使用Shiv或更改位置。有时他们只是和Js冲突。!
发布于 2014-02-21 03:28:34
您的样式表是从当前域加载的,而不是从异地CDN加载的吗?如果样式表托管在其他地方,请在您的域中本地托管它,看看这是否有帮助。
https://stackoverflow.com/questions/21184591
复制相似问题