image resizes my div ?

liunx

Guest
Hi,

I have a div on my html page : -


<div class="banner" id="banner">
<img src=http://www.webdeveloper.com/forum/archive/index.php/"../../images/banner/banner_centre.jpg" width="678" height="150">
</div>


and the problem i am gettin is my div is set to 150 height and so is my image but the div is being pushed out a little (abot 3px) by the image being there?

Any reason why


.banner {
background-color:#BFBFBD;
height: 150px;
text-align:center;
}


Thanks
Adamimg{
margin:0;
}
.banner {
background-color:#BFBFBD;
height: 150px;
text-align:center;
padding:0;
}no that doesn't work sorry :sPut the image in the background of the div and it will be "cropped" to the size you set for the div.
 
Back
Top