PDA

View Full Version : Can't create 100% height Div


Chapo
01-31-2012, 03:48 AM
Ok.... im trying to create a sidebar with a 100% height so it will be the full size of the site even if the browser expands. but it doesnt work , but i tried the 100% width just for curiosity and that works. How can i create this 100% height div so it will always have the full browser size

edbr
01-31-2012, 03:54 AM
use a faux-image background in a containing div

http://www.addedbytes.com/lab/faux-columns-for-liquid-layouts/

Chapo
01-31-2012, 05:05 AM
Thats a great help... do you have another one for keeping a div always at the bottom (footer)?

gentleone
01-31-2012, 05:16 AM
You will need to set a 100% height to the containing div(s), the body and html as well.
This article will help you understand: http://www.dave-woods.co.uk/index.php/100-height-layout-using-css/

gentleone
01-31-2012, 05:19 AM
use a faux-image background in a containing div

http://www.addedbytes.com/lab/faux-columns-for-liquid-layouts/
The faux image trick is to fake equal height columns, Ed. Thus not to get a 100% height sidebar, but to get a sidebar looks like it is the same height as the content div (for instance).

edbr
01-31-2012, 05:28 AM
yes im not in a very good explaining mood today , to pushed with keeping all the balls in the air

Chapo
02-02-2012, 04:52 PM
Ok, i uploaded the site so you could understand what im trying to do. You will see a left and right border in shape of waves of orange and blue. I want it the way it looks but i can't make those border edges %100 in height and also gave me a hard time to maintain the right border always float at right.

So basically i want those border edges float at left and right and be at %100 height, the content will be centered and will overlap the edges in case the browser narrows because the one i uploades the edges overlaps the content when the browser narrows.

www.graphicempire.com