So here's the rundown. I have an old page (created by someone else) that I was trying to update to reasonable standards. It has a header bar across the top and a footer bar across the bottom. The rest of the page is divided into two columns, a side bar on the left with info about the international organization, and the rest is info about the local chapter. The first thing I did was take out the table-based positioning and put everything in divs, but I keep running into problems. The worst part is that I know it would look fine in tables.
problem details: If I make the two divs in the center have absolute positioning, there is no way to predict the position of the bottom div to prevent it from covering up those above it. If I make one of the two divs float to one side or the other, the other div will wrap around it, and I want to maintain clean columns. I thought I could nest the two central divs in an outer div , then set the inner divs to style="bottom: inherit" or style="height: 100%" to prevent wrapping, but I couldn't find a solution.
Here's the code with which I ended up:
Expand|Select|Wrap|Line Numbers
- <body>
- <div style="width: 100%; height: 55px; background-color: #ccffff;">Header
- bar</div>
- <div style="width: 251px; height: 300px; background-color: #ffccff;
- left: inherit; position: absolute;">Side bar
- </div>
- <div style="position: relative; margin-left: 260px;">Main content div with
- a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info
- Main content div with a lot of info</div>
- <div style="width: 100%; height: 100px; background-color: #ffffcc;">footer
- bar
- </div>
- </body>
Jared