Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/76.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html 部分和小标签的Css在IE和Chrome中是不同的_Html_Css_Google Chrome_Internet Explorer - Fatal编程技术网

Html 部分和小标签的Css在IE和Chrome中是不同的

Html 部分和小标签的Css在IE和Chrome中是不同的,html,css,google-chrome,internet-explorer,Html,Css,Google Chrome,Internet Explorer,我有这个html来显示人的列表,它包含姓名和状态 <section class="box-time"> <ul class="group"> <li> <a class="fancybox fancybox.ajax" href="../loadFancybox.php"> <span class="info"> &l

我有这个html来显示人的列表,它包含姓名和状态

<section class="box-time">
    <ul class="group">
        <li>
            <a class="fancybox fancybox.ajax" href="../loadFancybox.php">
                <span class="info">
                    <strong>Name</strong>
                    <small>
                        <p id="pStatus" class="colorRed">Pending</p>
                    </small>
                </span>
            </a>
        </li>
    </ul>
</section>
问题是他们在这方面是不同的

下面是它在chrome中的显示方式

下面是它在IE中的显示方式

我还创作了一把小提琴:


我需要做哪些更改才能使这两种浏览器中的html看起来相同?

我估计您使用的是旧版本的IE,这是我可以复制问题的方式。旧版本不支持html5。您可以在网站标题中包含以下内容:

<!--[if lt IE 9]>
    <script>
        document.createElement('header');
        document.createElement('nav');
        document.createElement('section');
        document.createElement('article');
        document.createElement('aside');
        document.createElement('footer');
    </script>
<![endif]-->
这将告诉他们这些标记也是html标记。 最好删除不使用的标签


另一个解决方案是将该部分替换为div

,看起来对我来说是一样的。使用IE 11和chrome最新版本。你打开小提琴了吗?在小提琴中,它们是一样的,但我想小提琴的渲染是正确的。在我的应用程序中,它们都是蓝色的,就像我打开小提琴时看到的那样。您的应用程序在服务器上吗?我们可以查看它。它采用元素的默认颜色,并列出项目符号的样式。看起来不管出于什么原因ie没有采用你的css样式,但在fiddle中看起来是一样的,我们可能需要更多的数据来知道为什么我只是想知道问题是ie放在标签部分之外,但我不知道为什么。。。
<!--[if lt IE 9]>
    <script>
        document.createElement('header');
        document.createElement('nav');
        document.createElement('section');
        document.createElement('article');
        document.createElement('aside');
        document.createElement('footer');
    </script>
<![endif]-->