有没有办法创建一个 html 元素,即使网页上的内容发生变化,它也不会移动,它仍保持在相同的位置,并且其余内容环绕在它周围?
我想创建一条横跨动态网页的长线。当有人向网页添加更多内容时,该线应保持完整,不会像砖墙一样移动,其余内容会围绕它移动或跳过它。
视觉示例:
content content content content content contentcontent content
content content content content content contentcontent content co
--------------------------------------------------------------------(long line)
ntent content contentcontent contentcontent contentcontent content
content contentcontent contentcontent contentcontent contentcontent
请注意第二行文本如何绕过长行以在该行之后继续。
希望这是有道理的,
发现这个问题,这或多或少正是我想要的jQuery Split content based on height
问题并未得到解答。
最佳答案
.fencepost {float: left; width: 0.1px; height: 100px;}
.gate {float: left; clear: left; width: 99.9%; height: 30px;}
关于javascript - 将文本环绕固定分隔线,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14204136/