html - IE 未连接到外部 IE 特定的 CSS 文件

标签 html css

我在页面的头部有这个

 <!--[if IE]>
<link rel="stylesheet" type"text/css" href="ie.css" />
<![endif]-->

在 css 文件中我有这个

    <style>
h1 {
font-family: 'Paytone One', sans-serif;
font-size: 40px;
color: red;
position: absolute;
top:150px;
left: 400px;
}
h2 {
font-family: 'Paytone One', sans-serif;
font-size: 30px;
position: absolute;
top:0px;
left: 0px;
color: #FC3B3B;
}
h3 {
font-family: 'Paytone One', sans-serif;
font-size: 20px;
position: absolute;
top:300px;
left: 400px;
}
.image2 {
position: absolute;
top:0px;
left: 0px;
}
.box1 {
width: 100%;
height: 5px;
background-color:  #FC3B3B;
position: absolute;
top:0px;
left: 0px;
}
p {
position: absolute;
top:0px;
left: 0px;
font-size: 15px;
font-family: arial;
color: #585858;
}

</style>

IE 不接受这个,当我更改数字以定位页面内的内容时,它们不会移动。但是在 Chrome 浏览器中,定位正是我想要的位置

最佳答案

您需要删除 <style> CSS 文件中的标签。这样的文件只包含 CSS 而根本没有 HTML。

关于html - IE 未连接到外部 IE 特定的 CSS 文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14011453/

相关文章:

html - 为什么 flex 元素不缩小过去的内容大小?

html - 根据子类定位父元素

javascript - Chrome 扩展仅在具有特定内容的类上注入(inject) css

javascript - 滚动锁定时滚动的 CSS/JS 动画

javascript - 我怎样才能只获得 jQuery Mobile 1.4.1 结构?

html - 博主 (BlogSpot) : not open link and not change design

html - 如果太长如何打断H4文本

javascript - 淡出边框 (css)

html - CSS Center 在一个 div 中放置一堆图像

html - 如何将图像放在按钮上? (CSS)