How can I get an image to stretch the height of a DIV
class?
Currently it looks like this:
However, I would like the DIV
to be stretched so the image
fits properly, but I do not want to resize the `image.
Here is the CSS for the DIV
(the grey box):
.product1 {
width: 100%;
padding: 5px;
margin: 0px 0px 15px -5px;
background: #ADA19A;
color: #000000;
min-height: 100px;
}
The CSS being applied on the image:
.product{
display: inline;
float: left;
}
So, how can I fix this?
Best Answer
Add
overflow:auto;
to.product1