gpt4 book ai didi

php - 两列布局,左列高度限制右列高度,不知道为什么......?

转载 作者:行者123 更新时间:2023-11-28 19:10:04 24 4
gpt4 key购买 nike

我有点卡住了,这是因为我对 html/css 和 iframe 缺乏经验。

基本上,我有一个 LH 列,这是我的菜单。和一个 RH 专栏,其中包含我的内容。 RH 列是一个 iframe。

问题是我无法让 iframe 的高度等于 100%,它受到 LH 列高度的限制。

见下文; http://www.therussianfrostfarmers.com/

这让我抓狂,它似乎很容易修复。

这是相关html的一部分;

<div id='wrapper'>
<div id='header'>
<img src="images/titleBart.gif" alt="rff"/>
</div>

<div id='menu'>
<div class='container'>
<%obj_itop%>
<plug:front_index />
<%obj_ibot%>
</div>
</div>

<div id='content'>
<!-- text and image -->
<plug:front_exhibit />
<!-- end text and image -->
</div>

<div class='clear-both'>
<!-- -->
</div>
</div>

以及相应的CSS;

#wrapper { 
margin: 0 auto;
width:950px;
text-align: left;
background: #fff;
height:100% !important;
}

.clear-both { clear: both; }

#content {
width: 760px;
margin: 20px 0 0 190px;
padding:0;
height: 100% !important;
overflow: auto;
}

#menu {
width: 170px;
position:absolute;
margin:0;
padding:0;
overflow: auto;
}

.container {
margin:0;
padding:0;
}

任何帮助将不胜感激,

谢谢你

最佳答案

对此我不是 100% 确定,但我相当肯定,如果不使用 JavaScript 来动态调整 iFrame 的大小,就无法做到这一点。如果有,那可能并不容易。

之所以会发生这种情况,是因为 CSS 术语中的“100%”只会占用尽可能多的空间,页面上已有的内容。由于您已经有左侧列,因此 100% 只会达到该列的大小。

关于php - 两列布局,左列高度限制右列高度,不知道为什么......?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/847830/

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