The problem: I thought creating a main div / container (I called it wrapper) and setting the size was a smart idea. I want a picture on the left and text to go with it on the right. So, I thought ok, make the wrapper/container div, place it. I did that, then make a div, and put the image in the div. Check. I floated the image to the left side. Then I thought same thing for the text, piece of cake right? create a div for that, add in text, float it to the right. Why isn't it working? I don't understand, because as a concept it should work. I'm at a roadblock, and will keep thinking on this, but would appreciate anyone's help.
HTML code:
<div id="wrapper"> <div id="image"> <img border="0" src="images/main1.jpg" alt="FrontPageImage" width="450" height="335"></img> </div> <div id="sidebar"> <h1 id="textTitle"> Residential Services </h1> <p id="text">Lorem ipsum dolor ... yadda yadda</p> </div> </div>
CSS code:
#wrapper {
width: 940px;
margin: 40px;
margin-left: 20px;
}
#image {
width: 450px;
margin: 40px 20px 0px 0px;
float: top;
}
#sidebar {
width: 400px;
float: right;
margin: 0px;
}
#textTitle {
color: #ee282e;
background: #000000;
}
#text {
background: #ffffff;
}
So, with this code here is what I am getting:

Here is what I want:

New Topic/Question
Reply



MultiQuote







|