gpt4 book ai didi

javascript - Firefox 3.6

转载 作者:行者123 更新时间:2023-11-28 04:41:07 26 4
gpt4 key购买 nike

有一个包含 <p> 的标签在我的 html 代码中标记。但是 firefox 3.6 正在渲染 <p>破坏 html 的标签外的标签。包括不同 FF 版本在内的所有其他浏览器都可以很好地呈现它。请帮忙?

enter image description here

enter image description here

最佳答案

HTML 规范不允许<p>里面的元素<label>元素。当你写 invalid HTML,期望浏览器以不同的和不需要的方式进行错误恢复。

<!ELEMENT LABEL - - (%inline;)* -(LABEL) -- form field label text -->

“标签元素可以包含任意数量的‘内联’内容,但其他标签除外”

<!ENTITY % inline "#PCDATA | %fontstyle; | %phrase; | %special; | %formctrl;">

“内联由文本、被认为是‘fontstyle’、‘phrase’等的东西组成”

如果你follow the links through , 你不会找到 p在任何这些组中。

关于javascript - Firefox 3.6 <label><p> 渲染问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7037884/

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