Just wondering how to align text / image boxes in HTML?
So far I have done -
Code: |
<div class=textbox style=" float: left;
margin-top: 15px;
margin-left: 35px;
width: 410px;
height: auto;
background-color: red;">
<p> Test </p>
<p></p>
<p></p>
</div>
<div class=ad1 style="float: right;
margin-top: 15px;
margin-right: 35px;
width: 300px;
height: 240px;
background-color: blue;">
<p> Test </p>
<p></p>
<p></p>
</div>
<div class=ad2 style=" float: right;
margin-right: 35px;
margin-top:15px;
width: 300px;
height: 120px;
background-color: black;" >
<p> Test</p>
<p></p>
<p></p>
</div>
|
What I want is for textbox to be on the left and ad1 and ad2 to be on the right with ad1 ontop, a gap of 15px and then ad2 below it but I cant work it out!!
The problem Im having is ad2 wont go below ad1!! its like its using that as the margin as well and not the page body as the margin? ad2 keeps going under "textbox"
anyone know what Im doing wrong? Should I have them in the CSS or can I leave them in the html?
Thanks
George W Bush -
'...more and more of our imports are coming from overseas.'