如何左右对齐div和固定的高度和宽度

时间:2014-05-31 11:34:57

标签: html css

我只想左右对齐div并固定高度和宽度。

<asp:Panel id="Panel_Export_XLS" style="position: fixed; z-index: 100001; left: 293.5px; top: 34px;" runat="server"><div id="Div1" class="modalPopup" style="height: 600px; width: 1200px; overflow: auto; position: relative; box-shadow: rgb(0, 0, 0) 5px 5px 5px;">
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                        <tbody><tr>
                            <td align="right">
                                <div style="float: right; height: 15px;" align="right">
                                    <asp:ImageButton ID="ImageButton8" runat="server" 
                                        ImageUrl="../images/Close_button.jpg" BorderWidth="0px" 
                                        onclick="ibtnclose1_Click" />
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td align="left" valign="top">
                                <div style="float: left; width: 100%">
    <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
            <tbody><tr align="left">
                <td>
                    <span id="Span23" style="color:Red;font-size:12px;"></span>
                </td>
            </tr>
            <tr>
                <td class="middle_tab_border">
                    <div style="margin: 10px 10px 10px 10px;">
                        <table width="100%" border="0" cellspacing="0" cellpadding="0">
                            <tbody><tr>
                                <td valign="top" align="left">
                                    <div id="Div11">
                                        <table width="100%" border="0" cellspacing="0" cellpadding="0">
                                            <tbody><tr>
                                                <td width="10%" height="15" align="left" class="sidesection_top">
                                                    <span id="Span24">Export Master</span>
                                                </td>
                                                <td width="90%" class="inner_sidebg" align="right" height="15">
                                                </td>
                                            </tr>
                                            <tr>
                                                <td height="10">
                                                </td>
                                            </tr>
                                        </tbody></table>
                                    </div>
                                    </td>
                                    </tr>
                                    </tbody></table>
                                    </div>
                    <div id="parent" width="100%">
                    <div class="right" style="float:right;">
                                    <asp:FileUpload ID="FileUpload1" runat="server" />
                                    <br />
                                    <br />
                                    <br />
                                    <table>
                                     <tr>
                                                    <td align="center" valign="top" class="subtitle">
                                                        <div id="panelimport" class="thumb">
                                                        <img alt="" src="../images/wdb-351.png" name="ibtnimportxls" width="64" height="64" />
                                                            <br/>
                                                                <asp:LinkButton ID="lbut_import" runat="server">Import XLS</asp:LinkButton>
                                                            </div>
                                                            <div id="panelviewfile" class="thumb">
                                                        <img alt="" src="../images/1401550567_document_search.png" name="ibtnviewfile" width="64" height="64" />
                                                            <br/>
                                                                <asp:LinkButton ID="lbut_viewfile" runat="server">View File</asp:LinkButton>
                                                            </div>
                                                            </td>
                                                            </tr>
                                                            </table>
                                    </div>
                    <div class="left" style="width:300px;height:500px;overflow:scroll;padding-left:50px;">
                                        <table>
                                        <asp:Repeater ID="Repeater_Column_List" runat="server">
                                        <ItemTemplate>
                                        <tr>
                                        <td><asp:CheckBox ID="chk_column" runat="server" Text='<%#Eval("ColumnText")%>' Enabled="false" Checked='<%#Eval("AllowNulls")%>'/></td>
                                        <td>&nbsp;&nbsp;</td>
                                        <td><asp:TextBox ID="txt_col_" runat="server" CssClass="input"></asp:TextBox></td>
                                        </tr>
                                        </ItemTemplate>
                                        </asp:Repeater>
                                        </table>
                                        </div>
                    </div>
                                         </td>
    </tr>
    </tbody>
    </table>
    </div></td></tr>
                            <tr>
                                <td style="height: 10px;">
                                </td>
                            </tr>
                            <tr>
                                <td style="height: 10px;">
                                </td>
                            </tr>
                            <tr>
                                <td align="left">
                                    &nbsp;
                                    <div id="Div14">
                                            &nbsp;&nbsp;
                                    </div>
                                </td>
                            </tr>
                            <tr>
                                <td style="height: 10px;">
                                </td>
                            </tr>
                        </tbody></table>
    </div>
    </asp:Panel>

我怎么想解决这个问题:

enter image description here

看到这个左边div有一些额外的空间我只想删除它。

请帮我解决这个问题。

0 个答案:

没有答案