0

I am trying to create header , footer and a side bar that extends throughout the content but I am having problem. I have jsfiddle. but I am unsuccessful creating sidbar that is equal and with the containt in height.

kinkajou
  • 3,664
  • 25
  • 75
  • 128

3 Answers3

0

See this answer. The user suggests that you give a large bottom padding and a negative bottom padding of the same amount for the sidebar and main divs. Put a container around your sidebar and main div and hide the overflow in it.

Community
  • 1
  • 1
Arvind Sridharan
  • 3,885
  • 4
  • 29
  • 54
0

For a full length sidebar your best bet is probably the old faux columns method. You could do this in CSS but this is probably easier for you.

Put basically you want an image with your column background's in a thin long strip. You then add this as a background image to your parent div and it acts as pretend full height columns.

eg.

.container {
    background: url(your_image) repeat-y left top;
}

<div class="container">
    <div class="sidebar">SIDEBAR</div>
    <div class="content">CONTENT</div>
</div>

You can read more about it here - http://www.alistapart.com/articles/fauxcolumns/

SpaceBeers
  • 13,617
  • 6
  • 47
  • 61
0

Hey now define your sidebar and content bar

width in %

as like this

live demo http://jsfiddle.net/zAYru/5/

Rohit Azad Malik
  • 31,410
  • 17
  • 69
  • 97