Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Repeater overflowing out of div in Firefox.

Posted on 2010-09-09
5
Medium Priority
?
591 Views
Last Modified: 2012-05-10
I have a repeater that is overflowing outside of a div rather than extending it in Firefox but it looks fine in IE, Chrome and Safari.
<asp:Panel ID="pnlNotes" Visible="true" runat="server">
	    <br />
        <h2>Notes</h2>
        <br />
        <asp:Button ID="btnNote" Text="Add Note" OnClick="btnNote_Click" runat="server" />
        <asp:Repeater id="rptNotes" runat="server">
            <HeaderTemplate>
                <table class="indentedTable" cellSpacing="3" cellPadding="0" width="600px" align="left" border="1">
            </HeaderTemplate>

            <ItemTemplate>
                <tr>
                    <td align="left" width="10%">
                        <label class="coloredText">Name:</label>
                    </td>
                    <td width="45%">
                        <%# DataBinder.Eval(Container.DataItem, "Name") %>
                    </td>
                    <td align="left" width="10%">
                        <label class="coloredText">Time:</label>
                    </td>
                    <td width="35%">   
                        <%# DataBinder.Eval(Container.DataItem, "ActionTime") %>
                    </td>
                </tr>
                <tr>
                    <td colspan="4">
                        <%# DataBinder.Eval(Container.DataItem, "Note") %>
                    </td>
                </tr>
            </ItemTemplate>
    
            <SeparatorTemplate>
                <tr>
                    <td colspan="4"><hr color="black" /><br /></td>
                </tr>
            </SeparatorTemplate>

            <FooterTemplate>
                </table>
            </FooterTemplate>
        </asp:Repeater>
	    <br />
	</asp:Panel>

Open in new window

repeater.jpg
0
Comment
Question by:FIM2003
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 31

Expert Comment

by:MlandaT
ID: 33648235
You need to post the CSS code which you are using otherwise it is not possible to help you figure this one out. Particularly "indentedTable".



0
 
LVL 31

Expert Comment

by:MlandaT
ID: 33648251
Maybe post the HTML being output by the page as well then we just look at where the problem is coming from. This type of problem is normally just related to your CSS.
0
 

Author Comment

by:FIM2003
ID: 33648812
indentedTable is actually an old class that is no longer used in the current CSS file (I just missed it to take it out) so it wasn't specifying anything. Here is the outputted HTML code. coloredText is just font-weight: bold.
<div id="ctl00_contentplaceholder2_pnlNotes">
	
	    <br />

        <h2>Notes</h2>
        <br />
        
        
                <table class="" cellSpacing="3" cellPadding="0" width="600px" align="left" border="1">
            
                <tr>
                    <td align="left" width="10%">
                        <label class="coloredText">Name:</label>
                    </td>
                    <td width="45%">

                        ---
                    </td>
                    <td align="left" width="10%">
                        <label class="coloredText">Time:</label>
                    </td>
                    <td width="35%">   
                        10/12/2009 4:00:18 PM
                    </td>
                </tr>
                <tr>

                    <td colspan="4">
                        Assigned to --- in Purchasing
                    </td>
                </tr>
            
                <tr>
                    <td colspan="4"><hr color="black" /><br /></td>
                </tr>
            
                <tr>
                    <td align="left" width="10%">

                        <label class="coloredText">Name:</label>
                    </td>
                    <td width="45%">
                        ---
                    </td>
                    <td align="left" width="10%">
                        <label class="coloredText">Time:</label>
                    </td>

                    <td width="35%">   
                        10/12/2009 3:58:15 PM
                    </td>
                </tr>
                <tr>
                    <td colspan="4">
                        Assigned to --- in Purchasing
                    </td>
                </tr>
            
                </table>

            
	    <br />
	
</div>

Open in new window

0
 
LVL 31

Accepted Solution

by:
MlandaT earned 2000 total points
ID: 33648989
Try this:

1. Give the asp:Panel a width of 100%.
2. Add a style="overflow:auto" to the asp:Panel as well.

Works fine if the DIV is rendered as:

<div id="ctl00_contentplaceholder2_pnlNotes" style="overflow: auto; width:100%">
0
 

Author Closing Comment

by:FIM2003
ID: 33649342
This did the trick. Thank you!
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question