gazjones
01 Mar 2010, 12:23 PM
Hello all,
I'm new to the forum, and am hoping I can ask all of you if anyone can advise me on a (probably quite simple and amature) problem I'm having at the moment.
I've created a site, but am having problems getting DIVs to sit next to each other. I've tried "float: left", i've tried removing widths, padding, margins, and also adding them.
I am at a loss as to what to try next and wondered if anyone could advise me on the CSS I currently have?
Sidebar:
#sidebar {
display: block;
float: left;
width: 180px;
height: inherit;
word-spacing: 2px;
clear: none;
}
Content (that should run alongside)
#benefits_content {
float: left;
width: 669px;
}
I've also tried a container div:
#layout {
display: block;
margin: 0 auto;
width: 970px;
This was due to the IE6 issue of having float and margin together (causing double margin in IE6)
If anyone can offer me any advice or point me in the right direction I would be very grateful.
Thank you
Gary
P.S - IE6 = :smash:
I'm new to the forum, and am hoping I can ask all of you if anyone can advise me on a (probably quite simple and amature) problem I'm having at the moment.
I've created a site, but am having problems getting DIVs to sit next to each other. I've tried "float: left", i've tried removing widths, padding, margins, and also adding them.
I am at a loss as to what to try next and wondered if anyone could advise me on the CSS I currently have?
Sidebar:
#sidebar {
display: block;
float: left;
width: 180px;
height: inherit;
word-spacing: 2px;
clear: none;
}
Content (that should run alongside)
#benefits_content {
float: left;
width: 669px;
}
I've also tried a container div:
#layout {
display: block;
margin: 0 auto;
width: 970px;
This was due to the IE6 issue of having float and margin together (causing double margin in IE6)
If anyone can offer me any advice or point me in the right direction I would be very grateful.
Thank you
Gary
P.S - IE6 = :smash: