How do I stop nested <p>, <div>, <span> elements shfting other elements
I have created a footer, logo to the left, text in the middle, logo to the right, but the text isn't sitting centered (it's slightlly too far to the right, and the right hand logo has been pushed downwards by about 30px
css code (margins are set to minus to get the images to sit half over the box above.)
page code for footer
thanks.
----------------------------------------
Sometimes, when my code just won't behave, I take it outside and make it listen to britney spears music, and when it comes back it's really well behaved. I wonder if it's suffering from post tramatic stress syndrome now..
I have created a footer, logo to the left, text in the middle, logo to the right, but the text isn't sitting centered (it's slightlly too far to the right, and the right hand logo has been pushed downwards by about 30px
css code (margins are set to minus to get the images to sit half over the box above.)
Code:
.bottombox {
width: 762px;
height: 100%;
position: static;
margin: 0 auto; /* meaning top and bottom margins are 0, left and right are auto, which centers the box in standard browsers */
}
.aaleft {
float: left;
height: 60px;
width: 125px;
margin-top: -30px;
}
.aaright {
float: right;
height: 100px;
width: 101px;
margin-top: -66px;
}
.footertext {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: x-small;
color: #000000;
}
page code for footer
Code:
<div class="bottombox">
<img src="images/logo1.gif" alt="Tourisim Logo" width="125" height="60" class="aaleft">
<span class="footertext"><a href="home.php">Home</a> :: <a href="#">Book
Online</a> :: <a href="location.php">Location</a> :: <a href="attractions.php">Local Attractions</a><br>
© Motel Invercargill, 2004<br>
Design by </span>
<img src="images/rewardslogo.gif" alt="AA Rewards Logo" width="101" height="100" class="aaright">
</div>
thanks.
----------------------------------------
Sometimes, when my code just won't behave, I take it outside and make it listen to britney spears music, and when it comes back it's really well behaved. I wonder if it's suffering from post tramatic stress syndrome now..