tags:

views:

39

answers:

3

I have been struggling to try and place an image in the middle of a line of text.

"this is text THIS IS THE IMAGE this is text"

Any idea?

Thanks

+1  A: 

Try using CSS:

img {
    vertical-align: middle;
}
alopix
+1  A: 

The old non-standard valign='ABSMIDDLE' is massively deprecated.... Although it still works in every browser I know.

This should be a valid CSS workaround:

<img src="..." style="vertical-align:middle">
Pekka
A: 

I guess what you want is this?

<div>
this is text <img src="..." style="display:inline"> this is text
</div>
koko
The `img` element is inline by default.
Will Prescott