Basically When I resize the browser, the footer looks like it’s floating and overlaps the content by about 50px from the bottom (my footer height is 50px).But when I make the browser much smaller, the footer actually disappears
Would really appreciate it if you could give me some advice on this?
My main content includes
1. menu bar (on the left)
2. 2 column content (on the right)
I used div float.
I’ve checked all the margins, but this still doesn’t solve the problem!
Here's my HTML
<div id="page-wrap"><!-- Includes header -->
<div id="main-content">
<div id="left-nav">
<ul id="nav">....</ul>
</div><!-- END left-nav -->
<div id="right-right">
<p>text goes here</p>
</div><!-- END right-right -->
</div><!-- END text -->
</div><!-- END right-col -->
</div><!-- END main-content -->
</div><!-- END page-wrap -->
<div id="footer">
footergoes here
</div>
</body>
Here's my CSS
div#page-wrap {
width:800px;
margin-left:auto;
margin-right:auto;
}
div#main-content {
margin-left:auto;
margin-right:auto;
padding-bottom: 50px; /*Same height as footer*/
}
is the footer div inside your page-wrap div? if it is then you shouldnt have to set auto margin for left and right it should fit inside....if you don't then it could be conflicting with the height set you have for div#main-content div#left-nav...try putting the footer div with the br=clear css code (which you already have set) in the page-wrap div....if not try removing the height for the left-nav and see if that works...kinda hard to really know if i cant see
Hi repeater09,
YES it worked!
removing the height for the left-nav didn't work.
When I put '<br style="clear:both;" />' in div#footer in html, it created vertical scroll bar, but when I put it in div#main-content html, it worked apart from IE6
Bookmarks