.titletd
{
clear: both;
width: 100%;
height: 26px;
margin: 0px;
padding: 5px 0px 0px 0px;
font-size: 14px;
font-weight: bold;
color: #17368D;
text-align: left;
background-image: url(images/title_bg.gif);
background-repeat: repeat;
border-bottom: 1px solid #80A1C6;
}
.aub_bot
{
float: left;
width: 378px;
margin-top: 8px;
border: 1px solid #80A1C6;
}
.pr_con_title_l
{
float: left;
padding-top: 2px;
padding-left: 12px;
font-size: 14px;
color: #17368D;
font-weight: bold;
text-align: center;
}
.pr_con_title_r
{
float: right;
padding-top: 3px;
padding-bottom: 3px;
padding-right: 8px;
font-size: 12px;
color: #000000;
font-weight: normal;
}
.au366_comp
{
clear: both;
width: 375px;
}
.artt
{
clear: both;
width: 356px;
margin: 14px 0px 14px 0px;
}
.articlem
{
clear: both;
width: 356px;
padding: 4px 0px 0px 0px;
}
.articlem_left
{
float: left;
width: 280px;
text-align: center;
}
.articlem_right
{
float: right;
width: 50px;
color: #686868;
text-align: right;
}<div class="aub_bot">
    <asp:Repeater ID="rpt_GetPic" runat="server">
        <HeaderTemplate>
            <div class="titletd">
                <div class="pr_con_title_l">
                    <asp:Label ID="lbl_Title" runat="server" Text='<% #CreateTitle() %>'></asp:Label>
                </div>
                <div class="pr_con_title_r">
                    <asp:HyperLink ID="hl_More" runat="server" Text="更多>>" NavigateUrl='<% #CreateMoreURL()%>'></asp:HyperLink>
                </div>
            </div>
        </HeaderTemplate>
        <ItemTemplate>
            <div class="au366_comp">
                <div class="au_img">
                    <asp:Image ID="img_GetPic" runat="server" Width="153px" Height="103px" />
                </div>
            </div>
        </ItemTemplate>
        <FooterTemplate>
            </div>
        </FooterTemplate>
    </asp:Repeater>
    <asp:Repeater ID="rpt_gettitle" runat="server">
        <HeaderTemplate>
            <div class="artt">
        </HeaderTemplate>
        <ItemTemplate>
            <div class="articlem">
                <div class="articlem_left">
                    <asp:HyperLink ID="hylink_gettitle" runat="server" Text='<%#Eval("Title")%>' Target="_blank">
                    </asp:HyperLink>
                </div>
                <div class="articlem_right">
                    <asp:HyperLink ID="hylink_gettime" runat="server" Text='<%#DataBinder.Eval(Container.DataItem,"CreateDateTime","{0:m}")%>'
                        Target="_blank">
                    </asp:HyperLink>
                </div>
            </div>
        </ItemTemplate>
        <FooterTemplate>
            </div>
        </FooterTemplate>
    </asp:Repeater>
</div>
应该在右半个屏幕的一个小区域里  可是他却占了整整一个屏幕那么宽  为什么呢?

解决方案 »

  1.   

    看一下,
    <FooterTemplate> 
                 </div> 
    </FooterTemplate> 
    中的</div>好像是多出来的,看一下是不是这个标签的影响
      

  2.   

    Repeater 没有设大小吗,被它撑大的吧
      

  3.   

    <HeaderTemplate> 
                 <div class="titletd"> 
                     <div class="pr_con_title_l"> 
                         <asp:Label ID="lbl_Title" runat="server" Text=' <% #CreateTitle() %>'> </asp:Label> 
                     </div> 
                     <div class="pr_con_title_r"> 
                         <asp:HyperLink ID="hl_More" runat="server" Text="更多>>" NavigateUrl=' <% #CreateMoreURL()%>'> </asp:HyperLink> 
                     </div> 
                 </div> 
    </HeaderTemplate> 
    应该是去掉
    </HeaderTemplate> 前的那个</div>