homepage Welcome to WebmasterWorld Guest from 23.20.63.27
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / CSS
Forum Library, Charter, Moderators: not2easy

CSS Forum

    
Spacer.gif height="100%" for left navigation
Trying to get left navigation bar to stretch to 100% height
zreon




msg:3566085
 8:11 pm on Feb 4, 2008 (gmt 0)

I have this problem with my left navigation bar. Since every one of my pages is a different height my left navigation bar which has a background color stops. I would like the background color to span the entire height of the page.

What would be the best way to do this? I have tried using the spacer.gif setting height to 100% but this doesn't have any effect. I am familiar with css but not a expert by any means.

If someone could please point me in the right direction it would be greatly appreciated.

Thanks,
David

 

Moby_Dim




msg:3567662
 2:24 pm on Feb 6, 2008 (gmt 0)

May be try to add a border-left : [desired width]px, solid, #{desired color}; to your main content area. Then use position : absolute; for your left nav.bar (where width = border-left-width mentioned above).

BritishAgent




msg:3568008
 9:40 pm on Feb 6, 2008 (gmt 0)

What you can do is to wrap the entire content in a div that has the same background as the left nav. Then, when the other content flows downward your left nav will always be the same size because the div containing all of the content will be the same size as the content.

You may need to create a custom graphic that will be the background of this entire content div to make it look like the left nav div has a colored background because that div won't actually grow with the other div.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / CSS
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved