I'm trying to style the input text of a textarea so that the words being entered are highlighted. This is not as simple as just adding a background-color to the text area.
I'm trying to do something kind of like this example:
http://jsfiddle.net/terra823/t4esU/
html
<h1>This is what I'm trying to do with the input text</h1>
<p>Cool text</p>
<p>Cool text 2</p>
<p>Cool text 3</p>
<textarea> </textarea>
css
textarea{
width:130px;
height:130px;
}
p{
size:12px;
background:red;
color: white;
}
The difference is that I'd like the highlight to conform to the width and line-height of the text itself.
I realize this question seems very specific, but in doing research I couldn't come across anything that addresses styling textarea input text with either CSS or JS.
Appreciate any help!