开发者

Text and buttons outgrow popup box size

A legacy website that I am working on has a popup box that uses an iFrame and has nested tables. Within the cells of this table there is simple text and the last row of the table has two input boxes; one left aligned and one right aligned.

On screen resolution higher than 1024 X 768 everything is displayed within the borders of the box. The problem lies when I have resolution of 1024 X 768 or lower the text expands wider then the box and therefore horizontal scroll bars are turned on. I like to modify the inline css styling that so prominent in this design so the text and buttons render the same in any resolution and n开发者_StackOverflowo scroll bars are turned on.

The only thing I can see is that table width is set to 100%.

Any help will be a life saver.

Thanks

Please find screenshots attached:

> 1024 x 768 sample

Text and buttons outgrow popup box size

1024 X 768

Text and buttons outgrow popup box size

Here is the markup for the tables

<div align="center" style="padding: 8px 10px 4px;">
<table cellspacing="0" cellpadding="0" align="center" width="600px">
<tbody><tr>
    <td align="center" valign="top"> 
              <div class="container">
    <TABLE cellSpacing="5" cellPadding="5" width="100%" class="gradientHeader">
        <tr>
            <th width="100%">
                xxxxxx
            </th>
        </tr>
        <tr>
            <td width="100%">
                some text
            </td>
        </tr>
        <tr>
            <td width="100%" style="PADDING-LEFT: 10px">
                <table width="100%">
                    <tr>
                        <td width="100%">
                        <FIELDSET style="BORDER-TOP-STYLE: none; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BORDER-BOTTOM-STYLE: none;padding:0;">
                            <asp:RadioButtonList id="rbl" runat="server" />
                        </FIELDSET>
                            </td>
                    </tr>

                    <tr>
                    <td  align="left">
                    <AN IMAGE BUTTON>                       
                        </td>
                        <td  align="right">
                            <AN IMAGE BUTTON>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr>
            <td>
                <input type="hidden" name="hidProductId" id="hidProductId">

            </td>
        </tr>
    </table>
</div>
 </td></tr></tbody></table>


the table code you have given, will only scroll once a width less than 600px is reached because of the very first fixed width table

there is an error in colspans the cell with the fieldset in it should be colspan="2" and there is too much width="100%" there would be no need to put it every cell once the table is set to 100%.. however even with those there's nothing here that would force a scrollbar until <600px

I think the problem must be the width of the popup div and/or iframe instead

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜