|
Post by Ellethwen on Aug 6, 2007 16:27:55 GMT -5
I think I have a love-hate relationship with divs. Never mind the fact that I've been using them ever since I started webdesign; it's still really hard for me to get them to do what I want Anyways, I'm needing to get this layout centered and for the divs to extend to the same length no matter their length. I really don't understand why it's not working for me because I've done this before! But my coding doesn't seem to want to work. www.freewebs.com/starilluresource/wandering/index.html www.freewebs.com/starilluresource/wandering/style.cssIt won't center and the div's don't line up...how can I get it to do that?
|
|
|
Post by Betty Ann on Aug 6, 2007 17:33:14 GMT -5
This is a REALLY common problem in CSS that a LOT of people experience at one time or another. You have a few options:
1. Make a footer at the bottom of the page (it doesn't have to be visible) and have both columns extend to that. Search for "equal length columns css" or something in google and you will find all sorts of discussion (and some solutions).
2. Do it the easy way!! Just make a background that matches up with your left column and only repeats vertically. Your column won't extend all the way, but it will LOOK like your column is extending all the way. It's like faking your visitors out. It's really simple to do it that way; I do it a lot just because I don't feel like dealing with more CSS and different browser problems.
Also... your font and links are IMPOSSIBLE for me to read. Are you going to fix those?
|
|
|
Post by Ellethwen on Aug 6, 2007 18:37:14 GMT -5
Okay, I'll try those out
Haha, yes, I'll change them. I just stole the CSS from my layout from...somewhere...but I'll fix it all :-P
Thanks again; this stuff seems to really get me sometimes.
|
|
Amy-Chan
Dream Mirror
Water is a thing that flows!
????#??? ??????????? ?
Posts: 6,182
|
Post by Amy-Chan on Aug 6, 2007 19:56:34 GMT -5
change sidebar and contents - this seems to work for me, IE7 no center.. but you may need javascript to fix that, firefox is centered though.
#content { font-family: Georgia; font-size: 12px; margin-left:150px; position:relative; width: 480px; padding: 15px; margin-top: 0em; margin-bottom: 10em; background-color: #294762; }
#sidebar { font-family: Georgia; font-size: 12px; float:left; width: 150px; padding: 5px; margin-bottom: 10em; margin-top: 0em; background-color: #294762; }
using this test code with div borders activated <body> <div id="container"> <div id="header"></div> <div id="sidebar"></div> <div id="content"></div> </div> </body>
|
|