gpt4 book ai didi

html - 列 div 中的 float 被忽略

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

我有以下元素 here并已将列配置为在我的 CSS 中使用 float ,希望图像列位于左侧,内容位于其旁边。在 Chrome 中,内容位于图像下方。

CSS:

#WADADetails .propInfoCont .col1 
{
width:400px !important;
float:left !important;
}

#WADADetails .propInfoCont .col1 #loadarea img
{
width:420px !important;
height:315px !important;
float:left !important;
}

#WADADetails .propInfoCont .col2
{
width:230px; margin:0;
float:left !important;
}

最佳答案

您已将两列的宽度定义为可用空间的 100%:

#WADADetails div{ width:100% !important }

摆脱这一点将使两列并排。

关于html - 列 div 中的 float 被忽略,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25372116/

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