gpt4 book ai didi

css - 文本显示在 block 外

转载 作者:行者123 更新时间:2023-11-28 08:57:35 27 4
gpt4 key购买 nike

我尝试了 display:table-cell 但它没有用。我怎样才能在div中显示这个词。现在它显示溢出了 div。我在我的网页上使用 CSS2。提前致谢。

<div style=" width:60px; border-style: solid; border-width: 15px; display: block;">
<a href="http://www.w3schools.com" target="_blank">Visit W3Schoolseeeeee </a>
</div>
<div style="float: right; border-color: #ff33ff" width:50%;>Column 2</div>

最佳答案

使用自动换行:

a{
word-wrap: break-word;
}

demo

关于css - 文本显示在 block 外,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27070228/

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