tags:

views:

23

answers:

1
function pageLoad() {

    $('#accordion h3').click(function() {
        $(this).next().toggle();
        return false;
    }).next().hide();

<div id="accordion">
    <h3><a href="#">Section A</a></h3>
    <div id="a">
        <Ctrl:A id="a" runat="server"></Ctrl:A>
    </div>
    <h3><a href="#">Section B</a></h3>
    <div id="b">
         <Ctrl:B id="b" runat="server"></Ctrl:B>
    </div>
    <h3><a href="#">Section c</a></h3>
    <div id="c">
         <Ctrl:C id="c" runat="server"></Ctrl:C>
    </div>
</div>

The problem I am having is when say Setion A dn Section B are expanded, no scroll bars are showing in the broweser window and some fields are below the page and I have to tab to get to them and dont get a browser scrollbar.How can I get the scrollbar when the expansion is more than the height of the window?

A: 

Do you have overflow:hidden set on your page? The page should have a scrollbar when you expand past its boundaries unless you've told it not to. Are you doing any sort of fixed or absolute positioning?

Also, is this a big problem given that by your code, you should never have two sections open at once?

cdutson
I have 2 sections open when there are validation error messages on 2 sections....I dont have any overflow settings on the page set at all. All I want to do is if 2 sections are open, I want the scrollbar to show..I can get the height of the opened divs using jQuery and can check if they are greater than window.height but I dont know what to do after that and how to show the scrollbars.
chugh97
What about positioning? browsers by default should just... show scrollbars if the pages content gets too large. Do you have a demo page of this sitting somewhere that I can see?
cdutson