Inline Background Image for Text
I want to use a background image to highlight text in a paragraph. I do not want to use the background-color property for this as I want an image that look more like it was hand highlighted. How can I do this INLINE? I seem to only be able to do it as a block element and then the text breaks to its own line. I need it inline, a sentence here or there within a paragraph.
Example of it wor开发者_JAVA百科king but only as a block level element: link text
Please scroll down a bit to the YELLOW highlighted text. I need the highlighting to NOT cause the text to break onto the next line AND to end when the associated span ends, which could be right in the middle of a paragraph.
THANK YOU! I read all over the place and could not see a solution.
Change display: block
to display: inline
on .highlite1
.
What browser are you using? Works fine in Firefox 3.6.10 with display: inline
.
Setting the span to display:inline seems to work in Chrome and FF. Not tried it in others though.
精彩评论