I have text and image inside a div and I want the text to be aligned at the top of the image, not the middle.
Here’s how it looks: http://bitly.com/VSSoul
CSS:
.book1 {
width: 100%;
overflow: auto;
}
.book2 {
width: 100%;
overflow: auto;
}
.book1 img {
float: right;
width: 150px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
border-radius: 5px;
}
How do I make the text go to the top of the div, and not center relative of image?
It actually is aligned to the top. The h4 tag has default margins, so setting:
would do the trick.