开发者

CSS overflow issue in Firefox

开发者 https://www.devze.com 2023-04-02 20:14 出处:网络
I have a table coded as follows; <table id=\"c_month_tbl\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\" >

I have a table coded as follows;

<table id="c_month_tbl" cellspacing="0" cellpadding="0" border="0" >
<tbody>
<tr>
<td valign="top" class开发者_StackOverflow中文版="weekend_days">
<div class="block_out">
<div class="blockout_text">Some content ...Some content ...Some content ...Some content ...Some content ...</div>
</div>
</td>
</tr>
</tbody>
</table>

The CSS is as follows;

    td.weekend_days .blockout_text {
        margin-top: 14px;
    }
    .blockout_text {
        margin-top: 25px;
        padding: 3px;
        text-align: center;
    }

    #c_month_tbl{
        clear: both;
        width: 678px;
    }
    .block_out {
    height: 50px;
}

Now the layout appears fine if the content inside the td is less...But if there is more content, IE kind of expands the cell width/height and displays the content fine.

But in Firefox, the width/height for the content div remains fixed and does not expand as per the content, which makes the layout appear a bit broken..

I tried changing the overflow property for the containing td/div element , but it is not working fine in Firefox.

Please help me. Thank you.


Remove the class .blockout, or remove the height restriction on it. If you want it to be at least 50px tall, use min-height instead.

0

精彩评论

暂无评论...
验证码 换一张
取 消