无法在IE中设置HTML5元素的样式(尽管shiv和display:block) [英] Can't style HTML5 elements in IE (despite shiv and display:block)

查看:101
本文介绍了无法在IE中设置HTML5元素的样式(尽管shiv和display:block)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我似乎无法找出遗漏的东西。所有受影响的元素都有 display:block

I can't seem to work out what's missing. All the affected elements have display:block

标题的示例样式元素:

header
{
    width: 923px;
    height: 55px;
    background: #395168;
    margin-top: 25px;
}


推荐答案

解决了这个问题。我做的是我把脚本链接放在样式表链接下,突然IE 6-8应用了我的样式。

Solved the issue. What i did was that i put the script-link under the stylesheet link and suddenly IE 6-8 applied my styles.

<link rel="stylesheet" href="styles/style.css" type="text/css">

<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->

非常感谢您试图帮助我:)

Thank you so much for trying to help me :)

这篇关于无法在IE中设置HTML5元素的样式(尽管shiv和display:block)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆