gpt4 book ai didi

css - IE7 float 错误。是否有维护 html 的修复程序?

转载 作者:太空宇宙 更新时间:2023-11-03 18:58:15 25 4
gpt4 key购买 nike

这是我的问题的演示。这在 Chrome 和 Firefox 中正常工作。但是,在 IE7 中,未清除的 float 元素最终会出现在容器的顶部并排放置。 http://jsfiddle.net/eGAHx/

HTML:

<span class="bold floatLeft clearLeft">ISBN-13:&nbsp;</span>
<h2 class="floatLeft" itemprop="isbn">9780538735452</h2>
<span class="bold floatLeft clearLeft">ISBN:&nbsp;</span>
<h2 class="floatLeft">0538735457</h2>
<span class="bold floatLeft clearLeft">Edition:&nbsp;</span>
<span class="floatLeft" itemprop="bookEdition">3</span>
<span class="bold floatLeft clearLeft">Pub Date:&nbsp;</span>
<span class="floatLeft" itemprop="datePublished">2010</span>
<span class="bold floatLeft clearLeft">Publisher:&nbsp;</span>
<span class="floatLeft" itemprop="publisher">Brooks Cole</span>​

CSS:

.floatLeft{float:left}
.bold{font-weight:bold}
.clearLeft{clear:left}​

预期结果:
ISBN-13:9780538735452
书号:0538735457
版本: 3
发布日期: 2010
发布者:Brooks Cole

当前 IE7 结果:
ISBN-13:9780538735452053873545732010BrooksCole
国际标准书号:
版本:
发布日期:
发布者:

最佳答案

我完全不明白你为什么要 float 这些。

为什么不直接使用 <strong>左侧文本的标签,以及 <br />在每行的末尾?

关于css - IE7 float 错误。是否有维护 html 的修复程序?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12862466/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com